/* ==========================================================================
   MAIL WHITEPAPER PAGE — mani-mail-whitepaper-ltr.css
   Components: main-grid, panel, code-editor, terminal, api-endpoint,
               endpoint-method, architecture-*, tech-stack, tech-tag
   ========================================================================== */

/* --- DUAL PANEL GRID ---------------------------------------------------- */
.main-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

/* --- PANEL -------------------------------------------------------------- */
.panel {
    background: #fff;
    border: 1px solid var(--pg-border, #e2e8f0);
    border-radius: var(--pg-radius, 8px);
    padding: 22px;
    height: 520px;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
    overflow: hidden;
}

.panel:hover {
    border-color: var(--pg-green, #059669);
    box-shadow: 0 8px 28px rgba(5, 150, 105, 0.04);
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    border-bottom: 1px solid var(--pg-border, #e2e8f0);
    padding-bottom: 14px;
    flex-shrink: 0;
}

/* --- CODE EDITOR -------------------------------------------------------- */
.code-editor {
    flex: 1;
    background: #1e293b;
    border-radius: var(--pg-radius, 8px);
    padding: 18px;
    font-family: 'Courier New', monospace;
    font-size: 0.82rem;
    overflow-y: auto;
    color: #e2e8f0;
    text-align: left;
    line-height: 1.5;
    white-space: pre-wrap;
}

/* --- TERMINAL ----------------------------------------------------------- */
.terminal {
    flex: 1;
    background: #0f172a;
    border-radius: var(--pg-radius, 8px);
    padding: 18px;
    font-family: 'Courier New', monospace;
    font-size: 0.8rem;
    overflow-y: auto;
    color: #94a3b8;
    text-align: left;
    line-height: 1.5;
}

.status-valid { color: #10b981; font-weight: 700; }

/* --- ARCHITECTURE CARD -------------------------------------------------- */
.architecture-card {
    background: #fff;
    border: 1px solid var(--pg-border, #e2e8f0);
    border-radius: var(--pg-radius, 8px);
    padding: 36px;
    height: 100%;
    transition: all 0.3s cubic-bezier(0.19, 1, 0.22, 1);
    display: flex;
    flex-direction: column;
}

.architecture-card:hover {
    border-color: var(--pg-green, #059669);
    border-style: dashed;
}

.card-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.4rem;
    font-size: 1.4rem;
}

.architecture-label {
    font-size: 0.82rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    margin-bottom: 0.6rem;
}

.architecture-title {
    font-weight: 800;
    font-size: 1.6rem;
    margin-bottom: 0.8rem;
    color: var(--pg-navy, #0f172a);
}

.architecture-desc {
    color: var(--pg-muted, #475569);
    margin-bottom: 1.2rem;
    line-height: 1.6;
    font-size: 0.95rem;
}

/* --- TECH TAGS ---------------------------------------------------------- */
.tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 0.8rem;
}

.tech-tag {
    padding: 3px 10px;
    background: #f1f5f9;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--pg-navy, #0f172a);
}

/* --- API ENDPOINT ------------------------------------------------------- */
.api-endpoint {
    background: #1e293b;
    border-radius: 6px;
    padding: 10px 14px;
    margin: 6px 0;
    font-family: 'Courier New', monospace;
    color: #e2e8f0;
    font-size: 0.82rem;
}

.endpoint-method {
    display: inline-block;
    padding: 2px 7px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.7rem;
    margin-right: 8px;
    color: #fff;
}

.method-get  { background: #10b981; }
.method-post { background: #3b82f6; }
.method-put  { background: #f59e0b; }

/* --- DATABASE SCHEMA (DNS records table) -------------------------------- */
.database-schema {
    padding: 28px;
    margin: 1.5rem 0;
    background: #fff;
    border: 1px solid var(--pg-border, #e2e8f0);
    border-radius: var(--pg-radius, 8px);
}

.database-schema:hover {
    border-color: var(--pg-green, #059669);
    border-style: dashed;
}

.schema-table {
    width: 100%;
    border-collapse: collapse;
}

.schema-table th {
    text-align: left;
    padding: 12px 14px;
    border-bottom: 2px solid var(--pg-border, #e2e8f0);
    font-weight: 700;
    font-size: 0.85rem;
}

.schema-table td {
    padding: 10px 14px;
    border-bottom: 1px solid var(--pg-border, #e2e8f0);
    font-size: 0.85rem;
    color: var(--pg-muted, #475569);
}

.schema-table tr:hover { background: #f8fafc; }

/* --- SCRIPT SHOWCASE ---------------------------------------------------- */
.script-showcase {
    background: #0f172a;
    border-radius: var(--pg-radius, 8px);
    padding: 22px;
    margin: 1.5rem 0;
    font-family: 'Courier New', monospace;
    font-size: 0.82rem;
    color: #94a3b8;
    overflow-x: auto;
    line-height: 1.55;
}

.script-comment  { color: #64748b; font-style: italic; }
.script-string   { color: #34d399; }
.script-keyword  { color: #60a5fa; }
.script-function { color: #fbbf24; }
.script-variable { color: #c084fc; }

/* --- RESPONSIVE --------------------------------------------------------- */
@media (max-width: 992px) {
    .main-grid {
        grid-template-columns: 1fr;
    }

    .panel {
        height: 420px;
    }
}
