/* ============================================================
   Database Publication Landing Page Styles
   Used by publications/databases/pub.cfm via _PubContent.cfml.

   Brand palette:
     #264653  dark teal-slate  — primary (10.2:1 on white)
     #9E2A2B  crimson          — accent  ( 7.1:1 on white)
     #2a9d8f  teal             — decorative only (3.3:1, not for text)
     #21867b  dark teal        — decorative only (4.4:1, not for small text)
   ============================================================ */

/* ── Header Block ─────────────────────────────────────────── */
.dds-pub-header {
    border-bottom: 3px solid #264653;
    margin-bottom: 1.5em;
    padding-bottom: 0.75em;
}
.dds-pub-header h1 {
    margin-bottom: 0.25em;
}
.dds-series-label {
    font-size: 0.85em;
    color: #264653;
    margin-bottom: 0.25em;
}
.dds-series-label a {
    color: #21867b;
}
.dds-series-label a:hover {
    color: #264653;
}
.dds-authors {
    margin: 0.25em 0;
    font-size: 1em;
}
.dds-affiliations {
    margin: 0.15em 0;
    font-size: 0.875em;
    color: #444;
}
.dds-version-doi {
    margin: 0.5em 0 0;
    font-size: 0.875em;
    color: #444;
}
.dds-doi a {
    font-weight: bold;
    color: #21867b;
}
.dds-doi a:hover {
    color: #264653;
}

/* ── Content Sections ─────────────────────────────────────── */
.dds-section {
    margin: 1.75em 0;
}
.dds-section h2 {
    border-bottom: 2px solid #2a9d8f;
    padding-bottom: 0.2em;
    margin-bottom: 0.6em;
    color: #264653;
}
.dds-section h3 {
    margin-top: 1.1em;
    margin-bottom: 0.3em;
    font-size: 1em;
    color: #264653;
}

/* ── Citation ─────────────────────────────────────────────── */
.dds-citation {
    background: #f7f3f3;
    border-left: 4px solid #9E2A2B;
    margin: 0.75em 0;
    padding: 0.85em 1.2em;
    font-size: 0.9em;
    line-height: 1.55;
    color: #222;
}

/* ── Metadata Row (keywords, related) ────────────────────── */
.dds-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5em;
    align-items: flex-start;
}
.dds-meta-block {
    min-width: 12em;
}
.dds-meta-block h3 {
    margin-top: 0;
    font-size: 0.875em;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #264653;
    border-bottom: 1px solid #2a9d8f;
    padding-bottom: 0.2em;
    margin-bottom: 0.4em;
}

/* ── Keyword pills ────────────────────────────────────────── */
.dds-keyword-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.4em;
}
.dds-keyword-list li {
    background: #d4f0ed;
    border-radius: 3px;
    padding: 0.2em 0.6em;
    font-size: 0.8em;
    color: #1a4a44;  /* 8.3:1 on #d4f0ed — passes AA */
}

/* ── Directory layout code ────────────────────────────────── */
.dds-dir-layout {
    font-size: 0.9em;
    margin-bottom: 0.75em;
}
.dds-dir-layout code {
    background: #eaf7f5;
    padding: 0.1em 0.4em;
    border-radius: 3px;
    color: #264653;
}

/* ── README collapsible ───────────────────────────────────── */
.dds-readme > summary {
    cursor: pointer;
    font-weight: bold;
    color: #264653;  /* 10.2:1 on white — passes AA */
    padding: 0.3em 0;
    list-style: disclosure-closed;
}
.dds-readme[open] > summary {
    list-style: disclosure-open;
}
.dds-readme-content {
    background: #f8fafa;
    border: 1px solid #2a9d8f;
    padding: 0.85em 1em;
    font-size: 0.8em;
    white-space: pre-wrap;
    word-break: break-word;
    max-height: 22em;
    overflow-y: auto;
    margin-top: 0.5em;
    color: #222;
}

/* ── ESRI note ────────────────────────────────────────────── */
.dds-esri-note {
    background: #eaf7f5;
    border-left: 4px solid #21867b;
    padding: 0.75em 1em;
    margin-top: 1em;
    font-size: 0.9em;
}
.dds-esri-note h3 {
    margin-top: 0;
    color: #264653;  /* 10.2:1 on #eaf7f5 — passes AA */
}

/* ── Download grid ────────────────────────────────────────── */
.dds-download-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75em;
    margin: 1em 0;
}
.dds-download-btn {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    padding: 0.75em 1.1em;
    background: #264653 !important;   /* white text: 10.2:1 — passes AA */
    color: #fff !important;
    text-decoration: none !important;
    border-radius: 4px;
    min-width: 7em;
    max-width: 12em;
    text-align: center;
    line-height: 1.3;
}
.dds-btn-format {
    font-weight: bold;
    font-size: 1em;
}
.dds-btn-name {
    font-size: 0.7em;
    opacity: 0.85;
    word-break: break-all;
}
.dds-btn-size {
    font-size: 0.75em;
    opacity: 0.9;
    margin-top: 0.2em;
}

/* Full-package single download button */
.dds-download-full {
    display: inline-block;
    background: #264653 !important;
    color: #fff !important;
    text-decoration: none !important;
    padding: 0.75em 1.5em;
    border-radius: 4px;
    font-size: 1.05em;
    font-weight: bold;
    margin: 0.5em 0;
}
.dds-pkg-name {
    font-weight: normal;
    font-size: 0.85em;
}
.dds-pkg-size {
    font-weight: normal;
    font-size: 0.85em;
    opacity: 0.9;
}

/* Files coming soon notice */
.dds-files-soon {
    background: #fdf3f3;
    border-left: 4px solid #9E2A2B;
    padding: 0.7em 1em;
    font-size: 0.9em;
    color: #222;
}

/* ── Version history table ────────────────────────────────── */
.dds-version-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9em;
    margin: 0.5em 0;
}
.dds-version-table th,
.dds-version-table td {
    padding: 0.45em 0.75em;
    border: 1px solid #b0d4d0;
    text-align: left;
    vertical-align: top;
    color: #222;
}
.dds-version-table th {
    background: #264653;
    color: #fff;             /* 10.2:1 — passes AA */
    font-weight: bold;
}
.dds-version-table tr:nth-child(even) td {
    background: #eaf7f5;
}

/* ── Direct file URL list ─────────────────────────────────── */
.dds-url-list {
    list-style: none;
    padding: 0;
    margin: 0.5em 0;
}
.dds-url-list li {
    margin-bottom: 0.35em;
}
.dds-url-list code {
    font-size: 0.82em;
    background: #eaf7f5;
    padding: 0.15em 0.4em;
    border-radius: 3px;
    word-break: break-all;
    color: #264653;  /* 10.2:1 on #eaf7f5 — passes AA */
}

/* ── Responsive adjustments ───────────────────────────────── */
@media (max-width: 45em) {
    .dds-meta-row {
        flex-direction: column;
        gap: 1em;
    }
    .dds-download-grid {
        flex-direction: column;
    }
    .dds-download-btn {
        max-width: 100%;
    }
}
