/*
 * Darkroom: near-black page, charcoal panels with hairline borders, quiet
 * dim-gray text, amber safelight accent. Structure comes from borders, not
 * shadows. Mockup reference: design_mockups/01-darkroom.html.
 */
[data-theme="darkroom"] {
    /* Surfaces — charcoal page, slightly lifted panels */
    --color-bg: #101216;
    --color-surface: #181b21;
    --color-surface-hover: #1f232b;
    --color-surface-sunken: #13161b;

    /* Text — cool grays */
    --color-text: #e8eaed;
    --color-text-secondary: #c2c8d0;
    --color-text-muted: #9aa1ac;
    --color-text-faint: #5f6672;

    /* Inverse — flips to light-on-dark page */
    --color-surface-inverse: rgba(232, 234, 237, 0.95);
    --color-text-inverse: #101216;

    /* Borders — hairlines do the structural work */
    --color-border-subtle: #20242c;
    --color-border: #2a2f39;
    --color-border-strong: #353b47;
    --color-border-hover: #4a5263;

    /* Accent — amber safelight; dark ink on amber fills */
    --color-accent: #e8a33d;
    --color-accent-hover: #f2b455;
    --color-accent-soft: rgba(232, 163, 61, 0.14);
    --color-accent-soft-text: #e8a33d;
    --color-accent-soft-border: rgba(232, 163, 61, 0.35);
    --color-on-accent: #1a1205;

    /* Status — desaturated for dark panels; soft fills are translucent */
    --color-success: #4caf6e;
    --color-success-hover: #5dbf7e;
    --color-success-soft: rgba(76, 175, 110, 0.15);
    --color-success-soft-text: #7fd49d;
    --color-success-soft-border: rgba(76, 175, 110, 0.35);
    --color-danger: #e05d52;
    --color-danger-hover: #ea6f64;
    --color-danger-soft: rgba(224, 93, 82, 0.15);
    --color-danger-soft-text: #f0958d;
    --color-danger-soft-border: rgba(224, 93, 82, 0.35);
    --color-warning: #d9b13b;
    --color-warning-soft: rgba(217, 177, 59, 0.15);
    --color-warning-soft-text: #e6c869;
    --color-warning-soft-border: rgba(217, 177, 59, 0.35);
    --color-info: #5aa7d6;

    /* Neutral action — lifted slate buttons */
    --color-neutral: #3a4150;
    --color-neutral-hover: #4a5263;

    --color-disabled-bg: #232831;
    --color-disabled-text: #6b7280;

    /* Shape — mockup radii */
    --radius-sm: 6px;
    --radius-md: 10px;

    /* Elevation — deep and soft; borders carry most of the structure */
    --color-backdrop: rgba(0, 0, 0, 0.7);
    --shadow-navbar: 0 1px 0 #2a2f39;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 2px 8px rgba(0, 0, 0, 0.45);
    --shadow-lg: 0 4px 14px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 8px 28px rgba(0, 0, 0, 0.6);
    --shadow-inset: inset 0 -1px 0 rgba(0, 0, 0, 0.4);

    /* Thumbnail scrim — consumed only by the darkroom skin */
    --thumb-scrim: rgba(0, 0, 0, 0.35);

    /* Component hooks */
    --color-navbar-bg: rgba(16, 18, 22, 0.92);
}


/*
 * Darkroom theme skin: structural rules that tokens alone can't express
 * (frosted navbar, spaced amber wordmark, hairline photo cards with a bottom
 * scrim over the thumbnail, single-row card meta). Every rule is scoped to
 * [data-theme="darkroom"], so this file is inert for other themes; palette
 * values come from tokens.css.
 * Mockup reference: design_mockups/01-darkroom.html.
 *
 * Icons reuse the classic theme's line set via mask + currentColor, so this
 * theme ships no icon files of its own — only a favicon and placeholder.
 */

/* ---- navbar: frosted charcoal, aperture mark + amber wordmark ---- */
[data-theme="darkroom"] .navbar {
    backdrop-filter: blur(8px);
    border-bottom: var(--border-width) solid var(--color-border);
}

/* Brand carries the favicon mark so tab icon and logo match (app convention). */
[data-theme="darkroom"] .navbar-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--color-accent);
    font-size: var(--font-size-base);
    font-weight: 700;
    letter-spacing: 0.18em;
}

[data-theme="darkroom"] .navbar-brand::before {
    content: "";
    width: 22px;
    height: 22px;
    flex: none;
    background: url("/static/themes/darkroom/favicon.svg") center / contain no-repeat;
}

[data-theme="darkroom"] .nav-link:hover {
    background: transparent;
    color: var(--color-text);
}

/* ---- page header: bare heading line, no panel ---- */
[data-theme="darkroom"] .page-header {
    background: transparent;
    box-shadow: none;
    padding: 0;
}

/* ---- panels: hairline borders carry the structure ---- */
[data-theme="darkroom"] .sidebar,
[data-theme="darkroom"] .photo-sidebar,
[data-theme="darkroom"] .settings-section,
[data-theme="darkroom"] .editor-card,
[data-theme="darkroom"] .widget-card {
    border: var(--border-width) solid var(--color-border);
}

/* ---- photo cards: hairline frame, amber on hover, scrim over the thumb ---- */
[data-theme="darkroom"] .photo-card {
    position: relative;
    border: var(--border-width) solid var(--color-border);
}

[data-theme="darkroom"] .photo-card:hover {
    border-color: var(--color-accent);
    box-shadow: none;
}

/* darken the bottom of the thumbnail (base img height: 250px) so the card
   reads as one piece against bright photos */
[data-theme="darkroom"] .photo-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 250px;
    background: linear-gradient(to top, var(--thumb-scrim), transparent 40%);
    pointer-events: none;
}

[data-theme="darkroom"] .photo-card .photo-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
}

[data-theme="darkroom"] .photo-card .photo-date {
    margin-bottom: 0;
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
}

[data-theme="darkroom"] .photo-card .photo-people {
    justify-content: flex-end;
}

/* ---- icons: the default set (components/icons.css), a notch smaller ---- */
[data-theme="darkroom"] .nav-link[data-icon]::before,
[data-theme="darkroom"] .btn[data-icon]::before,
[data-theme="darkroom"] button[data-icon]::before {
    width: 16px;
    height: 16px;
}
