/* ==========================================================================
   1. CORE DESIGN PRINCIPLES & SYSTEM VARIANT FIELDS
   ========================================================================== */
:root {
    --sf-pro: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --apple-black: #1d1d1f;
    --apple-gray: #f5f5f7;
    --apple-dark-gray: #86868b;
    --apple-blue: #0066cc;
}

/* CHANGE THE TOP REBOOT BLOCK TO MATCH THIS EXACTLY */
html, body {
    max-width: 100%;
    margin: 0;
    padding: 0;
    background-color: #ffffff;
    font-family: var(--sf-pro);
    color: var(--apple-black);
    -webkit-font-smoothing: antialiased;
}

/* Base Editorial Block Adjustments */
.apple-body-text {
    color: #424245;
    font-size: 1.05rem;
    line-height: 1.6;
}

/* ==========================================================================
   2. MAIN CONTENT LAYOUT MODULES (APPLE DESIGN SYSTEM)
   ========================================================================== */
.apple-hero {
    background-color: var(--apple-gray);
    border-bottom: 1px solid #e5e5e7;
    padding-top: 30px;
    padding-bottom: 30px;
}

.apple-card {
    background: #ffffff;
    border: 1px solid #e5e5e7;
    border-radius: 18px;
    box-shadow: none;
    box-sizing: border-box;
}

/* Fluid Typography Scaler Breakpoints */
@media (max-width: 640px) {
    header.apple-hero h1 {
        font-size: 2rem !important;
    }
    .uk-card-body {
        padding: 20px 15px !important;
    }
}

@media (min-width: 960px) {
    .apple-hero {
        padding-top: 40px;
        padding-bottom: 40px;
    }
    .apple-card {
        transition: transform 0.3s ease, box-shadow 0.3s ease;
    }
    .apple-card:hover {
        transform: translateY(-2px);
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    }
}

/* ==========================================================================
   3. NAVIGATION UTILITIES (DESKTOP STICKY & MOBILE FAB)
   ========================================================================== */
/* Glassmorphic Desktop Side Dock */
.apple-sticky-nav {
    background: rgba(255, 255, 255, 0.8) !important;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid #e5e5e7;
    border-radius: 14px;
}

/* Native Nav Tracking Indicators */
.uk-nav-default > li > a {
    color: var(--apple-dark-gray);
    font-weight: 500;
    border-left: 2px solid transparent;
    padding-left: 10px;
}

.uk-nav-default > li.uk-active > a {
    color: var(--apple-blue);
    border-left-color: var(--apple-blue);
    font-weight: 600;
}

/* Floating Action Button (FAB) Trigger */
.apple-fab-btn {
    background-color: var(--apple-blue);
    color: #ffffff;
    border: none;
    border-radius: 50%;
    width: 56px;
    height: 56px;
    box-shadow: 0 4px 14px rgba(0, 102, 204, 0.3);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, transform 0.1s ease;
}

.apple-fab-btn:active {
    transform: scale(0.95);
}

/* ==========================================================================
   4. FIXED MOBILE NAVIGATION BOTTOM SHEET OVERRIDES
   ========================================================================== */
.apple-mobile-drawer {
    background: rgba(255, 255, 255, 0.98) !important;
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border-left: 1px solid #e5e5e7;
    padding: 24px !important;
    max-width: 270px;
}

/* HIGH CONTRAST INJECTION: Fixes light text string washing out */
.apple-mobile-drawer .uk-nav-default > li > a {
    color: var(--apple-black) !important; 
    font-weight: 500;
    font-size: 1rem;
    transition: color 0.2s ease;
}

.apple-mobile-drawer .uk-nav-default > li.uk-active > a,
.apple-mobile-drawer .uk-nav-default > li > a:hover {
    color: var(--apple-blue) !important;
}

.apple-mobile-drawer .uk-offcanvas-close {
    color: var(--apple-black) !important;
    top: 20px;
    right: 20px;
}

/* ==========================================================================
   5. GRAPHIC MEDIA AND RESPONSIVE CODE LAYOUTS
   ========================================================================== */
.apple-media-container {
    border-radius: 14px !important;
    overflow: hidden;
    border: 1px solid #e5e5e7;
    background-color: #000000;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box;
}

.apple-responsive-img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block;
    box-sizing: border-box;
}

.apple-carousel-caption {
    background: rgba(29, 29, 31, 0.75);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-radius: 10px;
    width: calc(100% - 20px) !important;
    margin: 0 auto;
    box-sizing: border-box;
}

.apple-code-box {
    background: var(--apple-gray);
    border-radius: 12px;
    font-family: SFMono-Regular, Consolas, Monaco, monospace;
    border: 1px solid #e5e5e7;
    padding: 12px;
    max-width: 100% !important;
    box-sizing: border-box;
    overflow-x: auto;
}

/* ==========================================================================
   6. INTERACTIVE BADGES, CONTROLS, & SYSTEM WARNING BOARDS
   ========================================================================== */
.apple-btn {
    background-color: var(--apple-blue);
    color: #ffffff;
    border-radius: 999px;
    font-weight: 500;
    font-size: 0.9rem;
    padding: 6px 18px;
    transition: background 0.2s ease;
    display: inline-block;
}

.apple-btn:hover {
    background-color: #0077ed;
    color: #ffffff;
    text-decoration: none;
}

.apple-badge {
    background-color: #e3f2fd;
    color: var(--apple-blue);
    font-weight: 600;
    border-radius: 6px;
    padding: 4px 8px;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.apple-alert-card {
    background: #fff5f5;
    border: 1px solid #ffccd5;
    border-radius: 18px;
    box-sizing: border-box;
    max-width: 100% !important;
}
