/*
 * Admin UI chrome (Week/Post screens) — plain hand-written CSS, deliberately NOT built
 * with Tailwind: specs/04-DESIGN-TOKENS.md's token/@apply system is for the branded
 * visuals (templates/social/visuals/), not this internal tool's own screens.
 */
:root {
    --green: #006633;
    --green-dark: #004423;
    --orange: #ed8d02;
    --ink: #1a1a1a;
    --paper: #f6f6f4;
    --line: #ddd;
}
* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--paper);
    color: var(--ink);
}
header.app-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px;
    background: var(--green);
    color: #fff;
}
header.app-nav a {
    color: #fff;
    text-decoration: none;
    font-weight: 600;
}
header.app-nav .brand {
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}
header.app-nav nav a { margin-left: 20px; opacity: 0.85; }
header.app-nav nav a:hover { opacity: 1; text-decoration: underline; }

main { padding: 24px; max-width: 1400px; margin: 0 auto; }

.week-toolbar {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}
.week-toolbar h1 { margin: 0; font-size: 22px; }
.week-toolbar form { display: inline-flex; gap: 8px; }
.week-toolbar input, .week-toolbar select {
    padding: 6px 10px;
    border: 1px solid var(--line);
    border-radius: 6px;
}
.btn {
    display: inline-block;
    padding: 8px 14px;
    border-radius: 6px;
    border: 1px solid var(--line);
    background: #fff;
    color: var(--ink);
    text-decoration: none;
    font-size: 14px;
    cursor: pointer;
}
.btn:hover { border-color: var(--green); }
.btn--primary { background: var(--green); color: #fff; border-color: var(--green); }
.btn--active { border-color: var(--green); font-weight: 700; }
.switcher { display: flex; gap: 8px; margin: 4px 0 16px; }

.day-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
}
.day-column h2 {
    font-size: 15px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--green-dark);
    border-bottom: 2px solid var(--line);
    padding-bottom: 6px;
}
.card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 10px;
    margin-bottom: 14px;
}
.card h3 { font-size: 14px; margin: 8px 0 2px; }
.card .meta { font-size: 12px; color: #666; margin-bottom: 8px; }
.thumb-row { display: flex; gap: 8px; flex-wrap: wrap; }
.thumb {
    display: block;
    width: 108px;
    height: 192px;
    overflow: hidden;
    position: relative;
    border-radius: 4px;
    border: 1px solid var(--line);
    background: #eee;
    text-decoration: none;
}
.thumb--suggested { border: 2px solid var(--green); }
.thumb--post { height: 135px; }
.thumb iframe {
    width: 1080px;
    height: 1920px;
    border: 0;
    transform: scale(0.1);
    transform-origin: top left;
    pointer-events: none;
}
.thumb--post iframe { height: 1350px; }
.thumb-label {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    font-size: 10px;
    padding: 2px 4px;
    text-align: center;
}

.post-layout { display: flex; gap: 32px; align-items: flex-start; flex-wrap: wrap; }
.post-preview iframe {
    width: 1080px;
    height: 1920px;
    border: 1px solid var(--line);
    transform: scale(0.4);
    transform-origin: top left;
}
.post-preview--post iframe { height: 1350px; }
.post-preview-box { width: 432px; height: 768px; overflow: hidden; }
.post-preview-box--post { height: 540px; }

.post-form { flex: 1; min-width: 320px; max-width: 480px; }
.post-form label { display: block; font-size: 13px; font-weight: 600; margin: 12px 0 4px; }
.post-form input[type=text], .post-form textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 6px;
    font: inherit;
}
.post-form textarea { min-height: 90px; }
.pill-status {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 2px 8px;
    border-radius: 999px;
    color: #fff;
}
.pill-status--draft { background: #999; }
.pill-status--ready { background: var(--green); }
.pill-status--blocked { background: #c0392b; }
.notice { font-size: 12px; color: #b45309; margin-top: 4px; }

.table { width: 100%; border-collapse: collapse; }
.table th {
    text-align: left;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #777;
    padding: 4px 12px 12px;
}
.table td { padding: 12px; border-top: 1px solid var(--line); font-size: 14px; vertical-align: middle; }
.table tr:hover td { background: #fafafa; }
.table td:first-child, .table th:first-child { padding-left: 0; }
.table td:last-child, .table th:last-child { padding-right: 0; text-align: right; }
.table .empty { padding: 24px 0; color: #888; text-align: center; font-size: 14px; }
.table .btn { padding: 5px 12px; font-size: 13px; }
.table .btn:hover { border-color: #c0392b; color: #c0392b; }

.field-grid { display: grid; gap: 16px; max-width: 420px; }
.field-grid > div { display: flex; flex-direction: column; gap: 6px; }
.field-grid label { font-size: 13px; font-weight: 600; }
.field-grid input[type=text] {
    padding: 9px 10px;
    border: 1px solid var(--line);
    border-radius: 6px;
    font: inherit;
}
.field-grid input[type=text]:focus {
    outline: none;
    border-color: var(--green);
    box-shadow: 0 0 0 3px rgba(0, 102, 51, 0.12);
}
