/* ================================================================
   DEVLOPAK SITE -- Marketing / about / docs components.
   Builds on devlopak-theme.css (--dk-* variables). Shared by the
   desktop and mobile site layouts.
   ================================================================ */

.dk-site-body {
    background: var(--dk-bg-deep);
    color: var(--dk-text);
    font-family: 'Segoe UI', Inter, Arial, sans-serif;
}

.dk-site-body button,
.dk-site-body input,
.dk-site-body textarea,
.dk-site-body select {
    font-family: inherit;
}

/* ---------------- HEADER / NAV ---------------- */
.dk-site-header {
    flex: 0 0 auto;
    background: var(--dk-bg);
    border-bottom: 1px solid var(--dk-border);
    padding: 0.7rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    position: relative;
    z-index: 20;
}

.dk-site-header::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--dk-grad-full);
    opacity: 0.6;
}

.dk-site-brand {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.2rem;
    letter-spacing: -0.01em;
}

.dk-site-brand__name {
    color: #fff;
}

.dk-site-nav {
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.dk-site-nav a {
    color: var(--dk-text-muted);
    text-decoration: none;
    font-size: 0.92rem;
    font-weight: 500;
    padding: 0.45rem 0.8rem;
    border-radius: var(--dk-radius-sm);
    transition: color var(--dk-duration) var(--dk-ease), background-color var(--dk-duration) var(--dk-ease);
}

.dk-site-nav a:hover,
.dk-site-nav a.is-active {
    color: var(--dk-text);
    background: rgba(139, 92, 246, 0.12);
}

.dk-site-nav .dk-site-nav__cta {
    margin-left: 0.4rem;
    color: #fff;
    background: var(--dk-grad-energy);
    box-shadow: 0 4px 16px var(--dk-red-glow);
}

.dk-site-nav .dk-site-nav__cta:hover {
    color: #fff;
    transform: translateY(-1px);
}

/* mobile nav toggle */
.dk-site-nav-toggle {
    display: none;
    background: transparent;
    border: 1px solid var(--dk-border);
    border-radius: var(--dk-radius-sm);
    color: var(--dk-text);
    padding: 0.4rem 0.55rem;
    cursor: pointer;
}

.dk-site-nav-toggle svg { width: 22px; height: 22px; }

/* ---------------- SHELL ---------------- */
.dk-site-shell {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

.dk-site-main {
    flex: 1 1 auto;
    position: relative;
    z-index: 1;
}

/* ---------------- SECTION SCAFFOLD ---------------- */
.dk-section {
    max-width: 1120px;
    margin: 0 auto;
    padding: 4rem 1.5rem;
}

.dk-section--tight { padding-top: 2rem; padding-bottom: 2rem; }

.dk-eyebrow-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.22em;
    font-size: 0.7rem;
    color: var(--dk-text-muted);
    padding: 0.4rem 0.9rem;
    border-radius: var(--dk-radius-full);
    border: 1px solid var(--dk-border);
    background: var(--dk-bg-card);
}

.dk-eyebrow-pill svg { width: 13px; height: 13px; opacity: 0.8; }

.dk-section__title {
    font-size: clamp(1.7rem, 3.2vw, 2.4rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin: 1rem 0 0.6rem;
    line-height: 1.15;
}

.dk-section__lead {
    font-size: 1.05rem;
    color: var(--dk-text-muted);
    line-height: 1.65;
    max-width: 60ch;
}

.dk-gradient-text {
    background: var(--dk-grad-energy);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

/* ---------------- HERO TWO PANELS ---------------- */
.dk-hero {
    display: flex;
    align-items: stretch;
    gap: 0;
    min-height: calc(100vh - 64px);
}

.dk-hero__left {
    flex: 1 1 52%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 3.5rem clamp(1.5rem, 5vw, 5rem);
    position: relative;
}

.dk-hero__left::after {
    content: "";
    position: absolute;
    top: 12%;
    right: 0;
    bottom: 12%;
    width: 1px;
    background: linear-gradient(180deg, transparent, var(--dk-border-hover), transparent);
}

.dk-hero__right {
    flex: 1 1 48%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 3.5rem clamp(1.5rem, 4vw, 4rem);
}

.dk-hero__title {
    font-size: clamp(2.2rem, 4.5vw, 3.4rem);
    font-weight: 800;
    line-height: 1.08;
    letter-spacing: -0.03em;
    margin: 1.1rem 0 1.2rem;
}

.dk-hero__subtitle {
    font-size: 1.15rem;
    color: var(--dk-text-muted);
    line-height: 1.7;
    max-width: 52ch;
    margin-bottom: 2rem;
}

.dk-hero__cta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

/* ---------------- BUTTONS ---------------- */
.dk-site-btn {
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.8rem 1.5rem;
    border-radius: var(--dk-radius-sm);
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    border: none;
    cursor: pointer;
    max-width: 100%;
    text-align: center;
    transition: box-shadow var(--dk-duration) var(--dk-ease), transform var(--dk-duration) var(--dk-ease), border-color var(--dk-duration) var(--dk-ease);
}

.dk-site-btn--primary {
    background: var(--dk-grad-energy);
    color: #fff;
    box-shadow: 0 4px 16px var(--dk-red-glow);
}

.dk-site-btn--primary:hover { transform: translateY(-1px); box-shadow: 0 8px 26px var(--dk-red-glow); color: #fff; }

.dk-site-btn--ghost {
    background: var(--dk-bg-card);
    color: var(--dk-text);
    border: 1px solid var(--dk-border);
}

.dk-site-btn--ghost:hover { border-color: var(--dk-border-hover); color: var(--dk-text); }

.dk-site-btn svg { width: 18px; height: 18px; }

/* ---------------- FEATURE / CARD GRID ---------------- */
.dk-grid {
    display: grid;
    gap: 1.25rem;
    margin-top: 2.25rem;
}

.dk-grid--3 { grid-template-columns: repeat(3, 1fr); }
.dk-grid--2 { grid-template-columns: repeat(2, 1fr); }

.dk-feature-card {
    background: var(--dk-bg-card);
    border: 1px solid var(--dk-border);
    border-radius: var(--dk-radius);
    padding: 1.5rem;
    box-shadow: var(--dk-shadow-card);
    transition: border-color var(--dk-duration) var(--dk-ease), box-shadow var(--dk-duration) var(--dk-ease), transform var(--dk-duration) var(--dk-ease);
}

.dk-feature-card:hover {
    border-color: var(--dk-border-hover);
    box-shadow: var(--dk-shadow-hover);
    transform: translateY(-2px);
}

.dk-feature-card__icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(139, 92, 246, 0.12);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.dk-feature-card__icon svg { width: 22px; height: 22px; color: var(--dk-purple-soft); }

.dk-feature-card__title { font-size: 1.1rem; font-weight: 650; margin-bottom: 0.4rem; }

.dk-feature-card__desc { color: var(--dk-text-muted); font-size: 0.95rem; line-height: 1.6; }

/* ---------------- STEP FLOW ---------------- */
.dk-flow {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 2rem;
}

.dk-flow-step {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    background: var(--dk-bg-card);
    border: 1px solid var(--dk-border);
    border-radius: var(--dk-radius);
    padding: 1.25rem 1.4rem;
}

.dk-flow-step__num {
    flex: 0 0 auto;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--dk-grad-energy);
    color: #fff;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 3px 10px var(--dk-red-glow);
}

.dk-flow-step__title { font-weight: 650; margin-bottom: 0.25rem; }

.dk-flow-step__desc { color: var(--dk-text-muted); font-size: 0.95rem; line-height: 1.6; }

/* ---------------- CODE / REQUEST-RESPONSE BLOCK ---------------- */
.dk-code {
    background: #0b0b11;
    border: 1px solid var(--dk-border);
    border-radius: var(--dk-radius);
    overflow: hidden;
    box-shadow: var(--dk-shadow-card);
    margin: 1rem 0;
}

.dk-code__bar {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.55rem 0.9rem;
    background: var(--dk-bg);
    border-bottom: 1px solid var(--dk-border);
}

.dk-code__method {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    padding: 0.15rem 0.5rem;
    border-radius: 6px;
    text-transform: uppercase;
}

.dk-code__method--get { background: rgba(59,130,246,0.15); color: var(--dk-blue-soft); }
.dk-code__method--post { background: rgba(34,197,94,0.15); color: var(--dk-success); }
.dk-code__method--res { background: rgba(139,92,246,0.15); color: var(--dk-purple-soft); }

.dk-code__path {
    font-family: 'SF Mono', 'Consolas', 'Courier New', monospace;
    font-size: 0.85rem;
    color: var(--dk-text-muted);
    overflow-x: auto;
    white-space: nowrap;
}

.dk-code pre {
    margin: 0;
    padding: 1rem 1.1rem;
    overflow-x: auto;
    font-family: 'SF Mono', 'Consolas', 'Courier New', monospace;
    font-size: 0.85rem;
    line-height: 1.6;
    color: #d6d6e7;
}

.dk-code pre .tok-key { color: var(--dk-blue-soft); }
.dk-code pre .tok-str { color: #7ee787; }
.dk-code pre .tok-cmt { color: var(--dk-text-dim); font-style: italic; }

/* ---------------- PRICING ---------------- */
.dk-price-card {
    background: var(--dk-bg-card);
    border: 1px solid var(--dk-border);
    border-radius: var(--dk-radius-lg);
    padding: 1.75rem;
    text-align: center;
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.dk-price-card--featured {
    border-color: var(--dk-border-active);
    box-shadow: var(--dk-shadow-red);
}

.dk-price-card__name { text-transform: uppercase; letter-spacing: 0.12em; font-size: 0.8rem; color: var(--dk-text-muted); }
.dk-price-card__price { font-size: 2.2rem; font-weight: 800; margin: 0.5rem 0; }
.dk-price-card__limit { color: var(--dk-text-muted); font-size: 0.95rem; margin-bottom: 1rem; }
.dk-price-card__desc { color: var(--dk-text-dim); font-size: 0.9rem; line-height: 1.55; }

.dk-pricing-grid {
    grid-template-columns: repeat(2, minmax(0, 320px));
    justify-content: center;
}

/* ---------------- CALLOUT ---------------- */
.dk-callout {
    background: var(--dk-bg-card);
    border: 1px solid var(--dk-border);
    border-left: 3px solid var(--dk-purple);
    border-radius: var(--dk-radius);
    padding: 1.1rem 1.3rem;
    color: var(--dk-text-muted);
    line-height: 1.65;
    margin: 1.5rem 0;
}

.dk-callout strong { color: var(--dk-text); }

/* ---------------- FOOTER ---------------- */
.dk-site-footer {
    flex: 0 0 auto;
    background: var(--dk-bg);
    border-top: none;
    padding: 0.45rem 1rem;
    position: relative;
    z-index: 10;
    overflow: visible;
}

.dk-site-footer::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: var(--dk-grad-full);
    opacity: 0.35;
}

.dk-site-footer__row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    width: 100%;
    margin: 0;
    flex-wrap: wrap;
}

.dk-site-footer__text { color: var(--dk-text-dim); font-size: 0.82rem; }

.dk-site-footer__aside {
    flex: 0 0 auto;
    text-align: right;
}

.identity-footer-resources {
    position: relative;
    display: inline-block;
}

.identity-footer-resources__toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.5rem;
    margin: 0;
    border: none;
    background: transparent;
    font-family: inherit;
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.2px;
    color: var(--dk-text-muted);
    cursor: pointer;
    border-radius: 6px;
    transition: color 0.15s ease, background-color 0.15s ease;
}

.identity-footer-resources__toggle:hover,
.identity-footer-resources__toggle:focus {
    color: var(--dk-text);
    background: rgba(139, 92, 246, 0.12);
    outline: none;
}

.identity-footer-resources__toggle:focus-visible {
    box-shadow: 0 0 0 2px rgba(139, 92, 246, 0.45);
}

.identity-footer-resources__chevron {
    width: 0.85rem;
    height: 0.85rem;
    opacity: 0.75;
    transition: transform 0.15s ease;
}

.identity-footer-resources.is-open .identity-footer-resources__chevron {
    transform: rotate(180deg);
}

.identity-footer-resources__menu {
    position: absolute;
    right: 0;
    bottom: calc(100% + 0.45rem);
    z-index: 1200;
    min-width: 10.5rem;
    max-height: min(16rem, 55vh);
    overflow-y: auto;
    margin: 0;
    padding: 0.35rem 0;
    list-style: none;
    background: var(--dk-bg-card);
    border: 1px solid var(--dk-border);
    border-radius: 10px;
    box-shadow: 0 -8px 28px rgba(0, 0, 0, 0.45);
}

.identity-footer-resources__menu::after {
    content: "";
    position: absolute;
    right: 1rem;
    bottom: -6px;
    width: 10px;
    height: 10px;
    background: var(--dk-bg-card);
    border-right: 1px solid var(--dk-border);
    border-bottom: 1px solid var(--dk-border);
    transform: rotate(45deg);
}

.identity-footer-resources__menu li {
    margin: 0;
}

.identity-footer-resources__menu a {
    display: block;
    padding: 0.45rem 0.85rem;
    font-size: 0.82rem;
    color: var(--dk-text-muted);
    text-decoration: none;
    white-space: nowrap;
    transition: color 0.12s ease, background-color 0.12s ease;
}

.identity-footer-resources__menu a:hover,
.identity-footer-resources__menu a:focus {
    color: var(--dk-text);
    background: rgba(139, 92, 246, 0.14);
    outline: none;
}

/* ---------------- RESPONSIVE ---------------- */
@media (max-width: 900px) {
    .dk-hero { flex-direction: column; min-height: 0; }
    .dk-hero__left::after { display: none; }
    .dk-hero__left, .dk-hero__right { padding: 2.5rem 1.5rem; }
    .dk-grid--3, .dk-grid--2 { grid-template-columns: 1fr; }
    .dk-pricing-grid { grid-template-columns: minmax(0, 320px); }
}

@media (max-width: 720px) {
    .dk-site-nav {
        display: none;
        position: absolute;
        top: 100%;
        right: 0;
        left: 0;
        flex-direction: column;
        align-items: stretch;
        background: var(--dk-bg);
        border-bottom: 1px solid var(--dk-border);
        padding: 0.6rem 1rem 1rem;
        gap: 0.25rem;
        z-index: 30;
    }

    .dk-site-nav.is-open { display: flex; }
    .dk-site-nav .dk-site-nav__cta { margin-left: 0; text-align: center; }
    .dk-site-nav-toggle { display: inline-flex; }
}
