/**
 * TopCrop traceability UI — shared brand shell (topcrop.in aligned).
 * Headings: Roboto Slab. Body: Source Sans 3 (linked from HTML).
 */

:root {
    --tc-font-heading: "Roboto Slab", ui-serif, Georgia, "Times New Roman", serif;
    --tc-font-body: "Source Sans 3", system-ui, -apple-system, "Segoe UI", sans-serif;
    --tc-primary: #14532d;
    --tc-primary-hover: #0f3d22;
    --tc-accent: #16a34a;
    --tc-accent-bright: #22c55e;
    --tc-bg: #fafaf9;
    --tc-surface: #ffffff;
    --tc-text: #1c1917;
    --tc-text-muted: #57534e;
    --tc-border: #e7e5e4;
    --tc-success-bg: #ecfdf5;
    --tc-success-text: #065f46;
    /* Legacy variable names used across pages */
    --primary: var(--tc-primary);
    --accent: var(--tc-accent-bright);
    --bg: var(--tc-bg);
    --text: var(--tc-text);
}

body.tc-branded {
    font-family: var(--tc-font-body);
    background: var(--tc-bg);
    color: var(--tc-text);
    margin: 0;
    padding: 0;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

.tc-main {
    padding: 20px 16px 40px;
    max-width: 1100px;
    margin: 0 auto;
    box-sizing: border-box;
}

@media (min-width: 640px) {
    .tc-main {
        padding: 24px 24px 48px;
    }
}

/* Full-width header */
.tc-site-header {
    position: sticky;
    top: 0;
    z-index: 200;
    background: var(--tc-surface);
    border-bottom: 1px solid var(--tc-border);
    box-shadow: 0 1px 3px rgba(28, 25, 23, 0.06);
}

.tc-site-header-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 10px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

@media (min-width: 640px) {
    .tc-site-header-inner {
        padding: 12px 24px;
    }
}

.tc-logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
    flex-shrink: 0;
}

.tc-logo-link:focus-visible {
    outline: 2px solid var(--tc-accent);
    outline-offset: 3px;
    border-radius: 8px;
}

.tc-logo-img {
    height: 42px;
    width: auto;
    display: block;
}

@media (max-width: 480px) {
    .tc-logo-img {
        height: 34px;
    }
}

.tc-site-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px;
    justify-content: flex-end;
}

.tc-nav-link {
    font-size: 13px;
    font-weight: 600;
    color: var(--tc-text-muted);
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 8px;
    transition: color 0.15s ease, background 0.15s ease;
}

.tc-nav-link:hover {
    color: var(--tc-primary);
    background: #f5f5f4;
}

.tc-nav-link.is-current {
    color: var(--tc-primary);
    background: var(--tc-success-bg);
    box-shadow: inset 0 0 0 1px rgba(34, 197, 94, 0.35);
}

.tc-nav-external {
    font-weight: 500;
    color: var(--tc-accent);
}

.tc-nav-external:hover {
    color: var(--tc-primary-hover);
    background: var(--tc-success-bg);
}

.tc-page-title {
    font-family: var(--tc-font-heading);
    font-weight: 700;
    color: var(--tc-primary);
    letter-spacing: -0.02em;
    line-height: 1.2;
}

/* Card container used inside .tc-main on each page */
.tc-card {
    background: var(--tc-surface);
    border-radius: 20px;
    box-shadow: 0 4px 24px rgba(28, 25, 23, 0.07);
    border: 1px solid var(--tc-border);
}
