/* ==========================================================================
   UUID Formatting Guide - TEXTBOOK ACADEMIC THEME
   ========================================================================== */

/* Abstract / Intro */
.intro-box {
    background: transparent;
    border-top: 2px solid #111;
    border-bottom: 2px solid #111;
    padding: 1.5rem 0;
    margin-bottom: 2rem;
    font-size: 1.15rem;
    color: #444;
    font-style: italic;
    text-align: center;
    box-shadow: none;
}

.h2-num {
    color: #111;
    font-size: 0.9em;
    margin-right: 0.5rem;
    font-weight: bold;
}
.h2-num::after {
    content: ".";
}

/* Figure / Academic Widgets */
.custom-hero-widget {
    background: #ffffff;
    color: #111;
    padding: 3rem 1.5rem;
    border: 1px solid #111;
    text-align: center;
    margin: 2.5rem 0;
    font-family: 'DM Mono', monospace;
    position: relative;
    box-shadow: 4px 4px 0px rgba(0,0,0,0.05);
}
.custom-hero-widget::before {
    content: "Fig 1. Standard UUID Example";
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: #fffcf7;
    padding: 0 10px;
    font-family: "Georgia", serif;
    font-size: 0.9rem;
    font-style: italic;
    color: #555;
}

.uuid-label {
    font-size: 0.9rem;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-family: "Georgia", serif;
}

.uuid-display {
    font-size: clamp(1.2rem, 3vw, 1.7rem);
    font-weight: bold;
    margin: 1.2rem 0;
    color: #111;
    background: none;
    -webkit-text-fill-color: initial;
}

.uuid-grid {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.uuid-seg {
    background: #f4f1ea;
    border: 1px solid #111;
    padding: 0.3rem 0.6rem;
    border-radius: 0;
    color: #111;
    box-shadow: none;
}

.sep {
    color: #111 !important;
    font-weight: bold;
}

/* Anatomy Section */
.uuid-anatomy {
    background: #ffffff;
    padding: 3rem 1.5rem;
    margin: 2.5rem 0;
    color: #111;
    font-family: 'DM Mono', monospace;
    border: 1px solid #111;
    position: relative;
    border-radius: 0;
}
.uuid-anatomy::before {
    content: "Fig 2. Segment Analysis";
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: #fffcf7;
    padding: 0 10px;
    font-family: "Georgia", serif;
    font-size: 0.9rem;
    font-style: italic;
    color: #555;
}

.uuid-full {
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: clamp(1rem, 2.5vw, 1.4rem);
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 0.25rem;
}

.uuid-full .seg {
    padding: 0.3rem 0.6rem;
    background: #ffffff;
    border: 1px solid #111;
    border-radius: 0;
}

/* Print-friendly highlights */
.seg-1 { border-bottom: 4px solid #b91c1c; color: #111; }
.seg-2 { border-bottom: 4px solid #15803d; color: #111; }
.seg-3 { border-bottom: 4px solid #ca8a04; color: #111; }
.seg-4 { border-bottom: 4px solid #7e22ce; color: #111; }
.seg-5 { border-bottom: 4px solid #1d4ed8; color: #111; }

.seg-labels {
    display: flex;
    justify-content: center;
    gap: clamp(0.5rem, 2vw, 2rem);
    flex-wrap: wrap;
}

.seg-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 0.85rem;
    text-align: center;
    background: #ffffff;
    border: 1px dashed #999;
    padding: 0.75rem;
    border-radius: 0;
    min-width: 100px;
    font-family: "Georgia", serif;
}

.seg-label .chars {
    font-weight: bold;
    margin-bottom: 0.3rem;
}

.seg-label .desc {
    color: #555;
}

/* Error Grid - Textbook layout */
.error-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.error-card {
    background: #fff;
    border: 1px solid #111;
    box-shadow: 3px 3px 0px rgba(0,0,0,0.05);
    border-radius: 0;
    transition: none;
}

.error-card:hover {
    transform: none;
    box-shadow: 3px 3px 0px rgba(0,0,0,0.05);
}

.error-card-head {
    background: #fee2e2;
    color: #991b1b;
    font-family: "Georgia", serif;
    font-weight: 700;
    padding: 1rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    border-bottom: 1px solid #111;
}

.error-card-body {
    padding: 1.25rem;
    color: #333;
    font-size: 1rem;
    line-height: 1.6;
}

.bad-example {
    margin-top: 1rem;
    padding: 0.75rem;
    background: #f9f9f9;
    border: 1px solid #e5e5e5;
    font-family: 'DM Mono', monospace;
    color: #b91c1c;
    word-break: break-all;
    font-size: 0.9rem;
    border-radius: 0;
    border-left: 3px solid #b91c1c;
    box-shadow: none;
}

/* Steps List */
.steps {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin: 2rem 0;
}

.step {
    display: flex;
    gap: 1.25rem;
}

.step-left {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.step-num {
    background: #ffffff;
    color: #111;
    border: 2px solid #111;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    flex-shrink: 0;
    font-family: "Georgia", serif;
    box-shadow: none;
}

.step-line {
    width: 2px;
    background: #111;
    flex-grow: 1;
    margin-top: 0.5rem;
}

.step-content {
    padding-bottom: 1rem;
}

.step-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #111;
    margin-bottom: 0.5rem;
    margin-top: 0;
    font-family: "Georgia", serif;
}

.step-body {
    color: #2b2b2b;
    line-height: 1.6;
}

/* Print Code Blocks - Terminal Window Aesthetic */
.code-block { margin: 2.5rem 0; background: #ffffff; border: 2px solid #111; box-shadow: 4px 4px 0px rgba(0,0,0,0.1); border-radius: 0; position: relative; }
.code-header { background: #111; padding: 0.6rem 1rem; display: flex; justify-content: space-between; align-items: center; }
.code-dots { display: flex; align-items: center; gap: 8px; }
.code-dots::before { content: ">_"; color: #a3e635; font-family: 'DM Mono', monospace; font-weight: bold; font-size: 1.1rem; letter-spacing: -1px; }
.code-dot { display: none; }
.code-lang { color: #fffcf7; font-size: 0.85rem; font-family: 'DM Mono', monospace; text-transform: uppercase; letter-spacing: 0.05em; }
.code-body { padding: 1.5rem; margin: 0; overflow-x: auto; color: #111; font-family: 'DM Mono', monospace; font-size: 0.95rem; background: #fdfcf8; border-top: 2px solid #111; border-left: 4px solid #111; line-height: 1.6; }

/* Syntax Highlighting for light bg */
.code-body .kw { color: #b91c1c; font-weight: bold; } 
.code-body .cm { color: #6b7280; font-style: italic; } 
.code-body .fn { color: #1d4ed8; font-weight: bold; } 
.code-body .num { color: #15803d; }

/* Best Practices List */
.practices-list { list-style: none; padding: 0; margin: 2rem 0; display: flex; flex-direction: column; gap: 1rem; }
.practices-list li { 
    display: flex; 
    gap: 1.25rem; 
    background: #ffffff; 
    padding: 1.5rem; 
    border: 1px solid #111; 
    border-radius: 0;
    align-items: flex-start;
    box-shadow: 3px 3px 0px rgba(0,0,0,0.05);
    transition: none;
}
.practices-list li:hover { border-color: #111; box-shadow: 3px 3px 0px rgba(0,0,0,0.05); }
.prac-icon { font-size: 1.5rem; flex-shrink: 0; line-height: 1; }
.prac-text { color: #2c2b29; line-height: 1.6; font-size: 1.05rem; }
.prac-text strong { color: #111; font-family: "Georgia", serif; }
