/* KENT STYLE CSS - WCAG AA COMPLIANT GREY/WHITE THEME */
/* Created: February 14, 2026 - Complete consolidated styles */
/* Performance Optimized - March 2, 2026 */
/* Pure grey palette, NO blue, NO other colors */
/* ONLY pictures & logos keep original colors - everything else is grey */

/* Performance optimizations */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

/* FORCE INDUSTRIAL THEME - KENT STYLE - WCAG AA COMPLIANT */
:root {
    /* EXACT KENT.CO.IN PALETTE - WCAG AA COMPLIANT */
    --primary-color: #333333;      /* Jet Grey - Primary Text (WCAG AA: 12.63:1 on white) */
    --secondary-color: #F5F5F5;    /* Tech White - Header/Nav background */
    --accent-color: #D1D1D1;       /* Silver - Borders */
    --bg-color: #FFFFFF;           /* Pure White - Main background */
    --action-color: #708090;       /* Slate Grey - Buttons (WCAG AA: 4.69:1) */
    --action-hover: #506070;       /* Darker Slate - Button hover (WCAG AA: 6.26:1) */
    
    /* Legacy compatibility */
    --pure-white: #FFFFFF;
    --gainsboro-grey: #F5F5F5;
    --light-grey: #E0E0E0;
    --silver-grey: #D1D1D1;
    --medium-grey: #B0B0B0;
    --slate-grey: #708090;
    --dark-grey: #505050;
    --charcoal: #333333;
    --pure-black: #000000;
    
    /* Semantic naming */
    --bg-primary: var(--bg-color);
    --bg-secondary: var(--secondary-color);
    --bg-tertiary: var(--light-grey);
    --text-primary: var(--primary-color);
    --text-secondary: var(--dark-grey);
    --text-inverse: var(--pure-white);
    --border-color: var(--accent-color);
    --hover-bg: var(--light-grey);
}

/* GLOBAL RESET */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* KILL ALL RANDOM COLORS - FORCE GREY/WHITE ONLY */
a, button, h1, h2, h3, h4, h5, h6, p, span, div, li, td, th, label, input, textarea, select {
    color: var(--primary-color) !important; /* Force Dark Grey text - NO MORE BLUE LINKS */
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--primary-color) !important;
    line-height: 1.6;
    background-color: var(--bg-color) !important; /* Force Pure White background */
}

/* EXCEPTION FOR HOVER - Turn black on hover */
a:hover {
    color: #000000 !important;
    text-decoration: underline;
}

/* BUTTONS - Slate Grey with proper contrast */
button, .button, .btn, input[type="submit"], input[type="button"] {
    background-color: var(--action-color) !important;
    color: #FFFFFF !important; /* White text on Slate Grey (WCAG AA: 4.69:1) */
    border: none !important;
}

button:hover, .button:hover, .btn:hover, input[type="submit"]:hover, input[type="button"]:hover {
    background-color: var(--action-hover) !important;
    color: #FFFFFF !important;
}

/* HEADER - Professional Grey (NO BLUE) */
.kent-header {
    background: var(--gainsboro-grey);
    color: var(--text-primary);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    border-bottom: 2px solid var(--border-color);
}

.kent-container {
    max-width: 100%;
    margin: 0 auto;
    padding: 0 1rem;
}

/* CENTERED CONTAINER LAYOUT - CKD REQUIREMENT */
.main-content,
.content-wrapper,
body > main,
body > .container {
    max-width: 100%;
    margin: 0 auto;
    padding: 0 1rem;
}

/* NAVIGATION - Grey only, NO colors */
.kent-nav {
    display: flex;
    align-items: center;
    gap: 0;
}

.kent-nav a {
    color: var(--text-primary);
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: background 0.3s;
}

.kent-nav a:hover {
    background: var(--hover-bg);
    color: var(--text-secondary);
    transform: translateY(-2px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

/* DROPDOWN HOVER EFFECTS WITH DELAY */
.dropdown-menu {
    transition: opacity 0.3s ease, transform 0.3s ease;
    transition-delay: 0s; /* No delay when showing */
}

.nav-dropdown:hover .dropdown-menu {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

/* Add delay when hiding dropdown - gives users time to move mouse */
.nav-dropdown .dropdown-menu {
    transition-delay: 0s, 0s, 300ms; /* 300ms delay before hiding */
}

.nav-dropdown:not(:hover) .dropdown-menu {
    transition-delay: 300ms; /* Stay visible for 300ms after mouse leaves */
}

.dropdown-menu a:hover {
    background: var(--light-grey);
    padding-left: 1.5rem;
    transition: all 0.3s ease;
}

/* MAIN CONTENT */
.main-content {
    min-height: 60vh;
    padding: 2rem 0;
}

/* TYPOGRAPHY - Black/Grey for readability, NO BLUE */
h1, h2, h3, h4, h5, h6 {
    color: var(--text-primary);
    font-weight: 600;
    margin-bottom: 1rem;
}

/* FONT HIERARCHY - CKD PART 10 REQUIREMENT */
h1 {
    font-size: 32px;
    font-weight: 700;
}

h2 {
    font-size: 24px;
    font-weight: 600;
}

p {
    font-size: 16px;
    line-height: 1.6;
}

/* LINE LENGTH FIX - CKD PART 10 REQUIREMENT (66 pages affected) */
/* Prevent "Wall of Text" - max 75 characters per line */
p, li, td, th {
    max-width: 75ch;
}

/* BUTTONS - Professional Grey (NO ORANGE) */
.kent-button {
    background: var(--slate-grey);
    color: var(--text-inverse);
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.3s;
}

.kent-button:hover {
    background: var(--dark-grey);
}

/* FOOTER - Professional Grey */
.kent-footer {
    background: var(--gainsboro-grey);
    color: var(--text-primary);
    text-align: center;
    padding: 2rem 0;
    margin-top: 2rem;
    border-top: 2px solid var(--border-color);
}

/* DROPDOWN NAVIGATION */
.nav-dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-toggle {
    cursor: pointer;
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--action-color);
    min-width: 250px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    border-radius: 8px;
    padding: 10px 0;
    z-index: 1000;
    border: 1px solid var(--border-color);
}

.nav-dropdown:hover .dropdown-menu {
    display: block;
}

.dropdown-menu a {
    display: block;
    padding: 12px 20px;
    color: var(--text-inverse);
    text-decoration: none;
    transition: all 0.2s ease;
}

.dropdown-menu a:hover {
    background: var(--action-hover);
    color: var(--text-inverse);
}

/* LEFT SIDEBAR NAVIGATION */
.left-sidebar-navigation {
    position: fixed;
    left: 0;
    top: 100px;
    z-index: 999;
}

.quick-nav-toggle {
    background: var(--slate-grey);
    color: var(--text-inverse);
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    border-radius: 0 8px 8px 0;
}

.quick-nav-dropdown {
    display: none;
    position: fixed;
    left: 0;
    top: 100px;
    width: min(90vw, 280px);
    height: calc(100vh - 100px);
    background: var(--pure-white);
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    overflow-y: auto;
    border-right: 2px solid var(--border-color);
}

.quick-nav-dropdown.active {
    display: block;
}

.quick-nav-link {
    display: block;
    padding: 10px 15px;
    color: var(--text-primary);
    text-decoration: none;
    transition: all 0.2s ease;
}

.quick-nav-link:hover {
    background: var(--gainsboro-grey);
    padding-left: 20px;
}

/* BREADCRUMBS */
.page-breadcrumbs {
    background: var(--gainsboro-grey);
    padding: 1rem 0;
    margin-bottom: 1rem;
}

.breadcrumb-list {
    list-style: none;
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.breadcrumb-link {
    color: var(--text-primary);
    text-decoration: none;
}

.breadcrumb-link:hover {
    color: var(--text-secondary);
}

/* RELATED PAGES */
.related-pages {
    padding: 2rem 0;
    background: var(--gainsboro-grey);
}

.related-pages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.related-page-card {
    background: var(--pure-white);
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.related-page-link {
    color: var(--text-primary);
    text-decoration: none;
}

.related-page-link:hover {
    color: var(--text-secondary);
}

/* DYNAMIC WIDGETS */
.dynamic-content {
    padding: 2rem 0;
}

.dynamic-widget {
    background: var(--pure-white);
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.widget-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

/* SIDE PANEL */
.side-panel {
    position: fixed;
    right: -300px;
    top: 0;
    width: 280px;
    height: 100vh;
    background: var(--pure-white);
    box-shadow: -2px 0 10px rgba(0,0,0,0.1);
    transition: right 0.3s ease;
    z-index: 1000;
}

.side-panel.open {
    right: 0;
}

.side-panel-toggle {
    position: fixed;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--slate-grey);
    color: var(--text-inverse);
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    border-radius: 8px 0 0 8px;
    z-index: 999;
}

/* FOOTER */
.footer {
    background: var(--dark-grey);
    color: var(--text-inverse);
    padding: 2rem 0;
    margin-top: 2rem;
}

.footer-content {
    max-width: 100%;
    margin: 0 auto;
    padding: 0 1rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.footer-section h3 {
    color: var(--light-grey);
    margin-bottom: 1rem;
    border-bottom: 2px solid var(--medium-grey);
    padding-bottom: 0.5rem;
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links a {
    color: var(--light-grey);
    text-decoration: none;
    display: block;
    padding: 0.5rem 0;
    transition: all 0.3s ease;
}

.footer-links a:hover {
    color: var(--pure-white);
    padding-left: 10px;
    border-left: 3px solid var(--medium-grey);
}

/* RESPONSIVE DESIGN */
@media (max-width: 768px) {
    .kent-nav {
        flex-direction: column;
    }
    
    .dropdown-menu {
        position: static;
        box-shadow: none;
        background: rgba(0,0,0,0.05);
    }
    
    .related-pages-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
}

/* ========================================
   GLOBAL MOBILE FIX - FORCE FIT TO VIEWPORT
   Purpose: Fix horizontal scrollbar on mobile (626px → 375px)
   Created: 2026-02-15 - Task 38
   ======================================== */
@media screen and (max-width: 768px) {
    /* 1. Force the Body to fit the Window */
    html, body {
        max-width: 100% !important;
        overflow-x: hidden !important; /* Hides the side scroll */
    }
    
    /* 2. Crush any wide elements (Images, Tables, Divs) */
    img, table, div, section, iframe, video {
        max-width: 100% !important; /* Shrink to fit */
        height: auto !important;    /* Keep aspect ratio */
        box-sizing: border-box !important;
    }
    
    /* 3. Fix the specific "626px" offender (likely a fixed-width container) */
    .container, .wrapper, .main, #content {
        width: 100% !important;
        padding-left: 15px !important;
        padding-right: 15px !important;
        margin: 0 !important;
    }
    
    /* 4. Fix Navigation Bar overflow */
    nav, header, .menu {
        width: 100% !important;
        white-space: normal !important; /* Allow text to wrap */
    }
}

/* Navigation Hover Effects */
nav a {
    transition: opacity 0.3s ease, color 0.3s ease;
}

nav a:hover {
    opacity: 0.8;
    text-decoration: underline;
}

.dropdown-content a:hover {
    background-color: #f5f5f5;
    color: #333;
}

/* ========================================
   NUCLEAR CSS RESET - FORCE GREY/WHITE THEME
   Purpose: Kill ALL blue/orange/green colors with !important
   ======================================== */

/* Force all links to grey (NO MORE BLUE LINKS) */
a, a:link, a:visited, a:hover, a:active {
    color: #708090 !important;
    text-decoration: none !important;
}

a:hover {
    color: #333333 !important;
    text-decoration: underline !important;
}

/* Force all text to dark grey */
body, p, h1, h2, h3, h4, h5, h6, span, div, li, td, th {
    color: #333333 !important;
}

/* Force background to white */
body {
    background-color: #FFFFFF !important;
}

/* Force buttons to slate grey */
button, .btn, input[type="button"], input[type="submit"] {
    background-color: #708090 !important;
    color: #FFFFFF !important;
    border: 1px solid #506070 !important;
}

button:hover, .btn:hover, input[type="button"]:hover, input[type="submit"]:hover {
    background-color: #506070 !important;
}

/* Kill all blue/orange/green colors */
*[style*="color: #0066cc"],
*[style*="color: #ff6600"],
*[style*="color: #00ff00"],
*[style*="color: blue"],
*[style*="color: orange"],
*[style*="color: green"] {
    color: #708090 !important;
}


/* ========================================
   MOBILE RESPONSIVENESS FIX - Task 54
   Purpose: Override 1200px max-widths on mobile devices
   ======================================== */

@media (max-width: 768px) {
    .kent-container,
    .container,
    body > main,
    body > .container,
    .footer-content {
        max-width: 100% !important;
        padding: 0 1rem !important;
    }
}
