/* DGTechQA — Selenium Practice pages
   Light white/gray theme matching main site (style.css) */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@500;600;700&family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root{
    --bg:#f8f9fb;
    --surface:#ffffff;
    --surface-2:#f1f4f8;
    --surface-3:#e8edf4;
    --border:#dde3ec;
    --border-soft:#e8edf4;
    --text:#0f172a;
    --muted:#4b5a6e;
    --muted-2:#8494a9;
    --green:#dc2626;
    --green-dim:#d1fae5;
    --amber:#d97706;
    --amber-dim:#fef3c7;
    --red:#dc2626;
    --blue:#2563eb;

    --font-display:'Space Grotesk', sans-serif;
    --font-body:'Inter', sans-serif;
    --font-mono:'JetBrains Mono', monospace;

    --radius:10px;
    --radius-lg:16px;
    --shadow-card:0 1px 3px rgba(0,0,0,.06), 0 8px 24px -8px rgba(0,0,0,.10);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: var(--font-body);
}

html{ scroll-behavior:smooth; }

body {
    background: var(--bg);
    background-image:
        linear-gradient(rgba(0,0,0,.018) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0,0,0,.018) 1px, transparent 1px);
    background-size: 48px 48px, 48px 48px;
    background-attachment: fixed;
    color: var(--text);
    line-height: 1.6;
    padding: 40px 0 60px;
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

.container > h1 {
    font-family: var(--font-display);
    font-size: 30px;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 26px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 10px;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 22px;
    color: var(--muted);
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    padding: 7px 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
    transition: .15s ease;
}

.back-link:hover {
    color: var(--green);
    background: var(--green-dim);
    border-color: var(--green);
}

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px 26px;
    margin-bottom: 22px;
    box-shadow: var(--shadow-card);
}

.card h2 {
    font-family: var(--font-display);
    color: var(--green);
    font-size: 18px;
    margin-bottom: 16px;
}

.card h3 {
    font-family: var(--font-display);
    color: var(--text);
    font-size: 16px;
    margin-bottom: 10px;
}

input[type="text"],
input[type="email"],
input[type="date"],
textarea {
    display: block;
    width: 100%;
    max-width: 400px;
    padding: 11px 14px;
    margin-bottom: 14px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text);
    font-size: 14px;
    font-family: var(--font-body);
    transition: border-color .15s, box-shadow .15s;
}

input::placeholder,
textarea::placeholder{
    color: var(--muted-2);
}

input:focus,
textarea:focus{
    outline: none;
    border-color: var(--green);
    box-shadow: 0 0 0 3px rgba(220,38,38,.12);
}

textarea {
    min-height: 90px;
    resize: vertical;
}

button {
    background: var(--green);
    color: #ffffff;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    font-family: var(--font-body);
    cursor: pointer;
    transition: .15s ease;
}

button:hover {
    background: #b91c1c;
    box-shadow: 0 0 0 3px rgba(220,38,38,.15);
}

pre {
    background: #0f172a;
    color: #cbd5e1;
    border: 1px solid #1e293b;
    padding: 16px 18px;
    border-radius: 10px;
    overflow-x: auto;
    font-family: var(--font-mono);
    font-size: 13px;
    line-height: 1.6;
    margin-top: 12px;
}

details {
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 12px;
}

details summary {
    font-weight: 600;
    cursor: pointer;
    color: var(--text);
}

details p {
    margin-top: 10px;
    color: var(--muted);
}

ul {
    list-style: none;
}

ul li {
    padding: 6px 0 6px 24px;
    position: relative;
    color: var(--muted);
}

ul li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--green);
    font-weight: 700;
}

p {
    color: var(--muted);
}

/* Drag and drop specific */
#drag {
    width: 150px;
    padding: 20px;
    background: var(--green-dim);
    color: var(--green);
    border: 1px solid var(--green);
    text-align: center;
    border-radius: 10px;
    margin-bottom: 20px;
    cursor: grab;
    font-weight: 600;
}

#drop {
    width: 250px;
    height: 100px;
    border: 2px dashed var(--border);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--muted-2);
    font-weight: 600;
    background: var(--surface);
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

table th,
table td {
    border: 1px solid var(--border);
    padding: 11px 14px;
    text-align: left;
}

table th {
    background: var(--surface-2);
    color: var(--text);
    font-family: var(--font-display);
}

table td {
    background: var(--surface);
    color: var(--muted);
}

iframe {
    border: 1px solid var(--border);
    border-radius: 10px;
    margin-bottom: 16px;
}

/* ── Responsive ── */
@media (max-width: 768px) {
    body { padding: 24px 0 48px; }
    .container { padding: 0 16px; }
    .container > h1 { font-size: 22px; }
    .card { padding: 18px; }
    input[type="text"],
    input[type="email"],
    input[type="date"],
    textarea { max-width: 100%; }
    #drag { width: 120px; padding: 14px; }
    #drop { width: 100%; }
    table { font-size: 13px; }
    table th, table td { padding: 8px 10px; }
}
