/* Tamraght Forum – skills, collabs, gigs, Local guide. Uses forum.css tokens (day + night). */

:root { --ag-gig-bg: #E6EFEE; --ag-gig-ink: #17485A; --ag-guide: #2F6B4A; }
body.tmf-night { --ag-gig-bg: #1F4352; --ag-gig-ink: #CFE6EC; --ag-guide: #8FD3A8; }

.tmf-badge--guide { background: var(--ag-guide); color: var(--surface); }
body.tmf-night .tmf-badge--guide { color: #0E1B26; }

/* Skill chips */
.tmf-ag-chips { list-style: none; margin: 0 0 12px; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.tmf-ag-chips li { font-size: .82rem; font-weight: 600; padding: 4px 10px; border-radius: var(--r-pill); background: var(--sand-2); color: var(--ink); line-height: 1.3; }
.tmf-ag-chips--gig li { background: var(--ag-gig-bg); color: var(--ag-gig-ink); }
.tmf-ag-skillpanel__label { margin: 4px 0 6px; font-size: .78rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.tmf-ag-cardskills { display: block; margin-top: 3px; font-size: .78rem; font-weight: 600; color: var(--ag-gig-ink); }
.tmf-ag-skillfilter { align-items: center; }
.tmf-ag-skillfilter > .tmf-muted { font-size: .85rem; margin-right: 4px; }
.tmf-ag-tabs { margin-bottom: 18px; }

/* Skills form */
.tmf-ag-group { border: 1px solid var(--line); border-radius: var(--r-md); margin-bottom: 10px; background: var(--bg); }
.tmf-ag-group summary { padding: 12px 16px; cursor: pointer; display: flex; align-items: center; gap: 8px; }
.tmf-ag-skillrows { list-style: none; margin: 0; padding: 0 12px 10px; }
.tmf-ag-skillrows li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 12px; padding: 8px 4px; border-top: 1px solid var(--line); }
.tmf-ag-skillrows__name { font-weight: 600; }
.tmf-ag-seg { display: inline-flex; border: 1px solid var(--line); border-radius: var(--r-pill); overflow: hidden; background: var(--surface); }
.tmf-ag-seg label { position: relative; cursor: pointer; }
.tmf-ag-seg input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.tmf-ag-seg span { display: block; padding: 6px 12px; font-size: .82rem; font-weight: 600; color: var(--muted); white-space: nowrap; }
.tmf-ag-seg label + label span { border-left: 1px solid var(--line); }
.tmf-ag-seg input:checked + span { background: var(--sand-2); color: var(--ink); }
.tmf-ag-seg label:last-child input:checked + span { background: var(--ocean); color: var(--ocean-ink); }
.tmf-ag-seg input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: -2px; }

/* Gig form: pills */
.tmf-ag-needed { border: 0; padding: 0; margin: 0 0 16px; }
.tmf-ag-needed legend { font-weight: 600; font-size: .92rem; margin-bottom: 8px; }
.tmf-ag-needed__label { margin: 10px 0 6px; font-size: .78rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.tmf-ag-needed__opts { display: flex; flex-wrap: wrap; gap: 6px; }
.tmf-ag-pill { position: relative; cursor: pointer; }
.tmf-ag-pill input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.tmf-ag-pill span { display: inline-block; padding: 7px 12px; border: 1px solid var(--line); border-radius: var(--r-pill); font-size: .86rem; font-weight: 600; background: var(--surface); color: var(--ink); }
.tmf-ag-pill input:checked + span { background: var(--ocean); border-color: var(--ocean); color: var(--ocean-ink); }
.tmf-ag-pill input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Gig list */
.tmf-ag-giglist { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 16px; margin-bottom: 20px; }
.tmf-ag-gigcard { margin: 0; display: flex; flex-direction: column; }
.tmf-ag-gigcard__top { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 6px; }
.tmf-ag-gigcard__top .tmf-badge { margin: 0; }
.tmf-ag-gigcard__title { font-size: 1.2rem; margin: 0 0 6px; }
.tmf-ag-gigcard__title a { color: var(--ink); text-decoration: none; }
.tmf-ag-gigcard__title a:hover { color: var(--accent); }
.tmf-ag-gigcard__need { margin: 8px 0 6px; font-size: .85rem; }
.tmf-ag-gigcard__foot { margin: auto 0 0; font-size: .82rem; }
.tmf-ag-gigcard--filled, .tmf-ag-gigcard--closed, .tmf-ag-gigcard--past { opacity: .75; }
.tmf-ag-state--open { background: var(--ag-gig-bg); color: var(--ag-gig-ink); }
.tmf-ag-state--filled { background: #E3EEE6; color: var(--success); }
body.tmf-night .tmf-ag-state--filled { background: #183A2C; color: #BFE3CB; }
.tmf-ag-past { margin-top: 10px; }
.tmf-ag-past .tmf-ag-giglist { padding: 0 16px 16px; }

/* Gig page */
.tmf-ag-gig__head { margin: 8px 0 18px; }
.tmf-ag-gig__head .tmf-badge { margin: 0 0 8px; }
.tmf-ag-gig__head h1 { font-size: clamp(1.7rem, 4vw, 2.5rem); font-weight: 800; letter-spacing: -0.02em; margin: 0 0 10px; overflow-wrap: anywhere; }
.tmf-ag-gig__head .tmf-post__who .tmf-badge { margin: 0; }
.tmf-ag-gig__grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 24px; align-items: start; margin-bottom: 28px; }
.tmf-ag-facts { margin-bottom: 14px; }
.tmf-ag-gig__body { margin: 14px 0; }
.tmf-ag-answer form { display: grid; gap: 8px; }
.tmf-ag-answer label { font-weight: 600; font-size: .92rem; }
.tmf-ag-answer .tmf-btn { justify-self: start; }
.tmf-ag-answer p { margin: 6px 0 10px; }
.tmf-ag-section { margin-bottom: 28px; }
.tmf-ag-section > h2 { font-size: 1.3rem; }
.tmf-ag-people { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); gap: 14px; }
.tmf-ag-person { margin: 0; display: grid; gap: 10px; align-content: start; }
.tmf-ag-person__top { display: flex; gap: 12px; align-items: center; }
.tmf-ag-person__top a { color: var(--ink); text-decoration: none; }
.tmf-ag-person__top a:hover { color: var(--accent); }
.tmf-ag-person .tmf-ag-chips { margin: 0; }
.tmf-ag-person .tmf-quote { margin: 0; }
.tmf-ag-collabs, .tmf-ag-mygigs { margin-bottom: 20px; }
.tmf-ag-collabs .tmf-ag-people { margin-bottom: 8px; }
.tmf-ag-skillform { margin-top: 20px; }

/* Collab popover */
.tmf-ag-collab { margin-left: 0; }
.tmf-ag-collab > summary.tmf-btn { color: var(--surface); }
body.tmf-night .tmf-ag-collab > summary.tmf-btn { color: #0E1B26; }
.tmf-ag-collab .tmf-report__form { right: auto; left: 0; }
.tmf-ag-collab .tmf-report__form label { font-weight: 600; }

@media (max-width: 900px) {
	.tmf-ag-gig__grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
	.tmf-ag-collab .tmf-report__form { position: fixed; left: 16px; right: 16px; top: auto; bottom: 16px; width: auto; z-index: 50; }
	.tmf-ag-skillrows li { display: grid; gap: 6px; padding: 10px 0; }
	.tmf-ag-seg { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); width: 100%; }
	.tmf-ag-seg span { padding: 8px 4px; font-size: .8rem; text-align: center; }
}

/* Home: a young board */
.tmf-home-feed .tmf-rows + .tmf-empty { margin-top: 16px; padding: 32px 20px; }
.tmf-home-h1 { margin: 0 0 6px; font-family: var(--font-body, inherit); font-size: .78rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); line-height: 1.4; }
