/* =========================================
   CSS Variables & Professional Theme
========================================= */
:root {
    --primary-color: #0F172A; /* Deep Navy Blue */
    --secondary-color: #EA580C; /* Vibrant Saffron */
    --accent-color: #2563EB; /* Bright Blue */
    --bg-color: #F8FAFC; 
    --surface-color: #FFFFFF;
    --text-color: #334155;
    --light-text: #64748B;
    --border-color: #E2E8F0;
    --step-bg: #F1F5F9;
    --footer-bg: #1E293B;
    --danger-color: #DC2626; /* For Challans/Alerts */
    --success-color: #16A34A; /* For Fitness/PUC */
}

/* =========================================
   Basic Resets
========================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
}

a {
    text-decoration: none;
    color: var(--accent-color);
    transition: color 0.3s;
}

a:hover { color: var(--secondary-color); }

/* =========================================
   Navigation & Mobile Menu
========================================= */
.top-nav {
    background-color: var(--surface-color);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--primary-color);
}

.nav-logo span { color: var(--secondary-color); }

.nav-links {
    list-style: none;
    display: flex;
    gap: 20px;
}

.nav-links a {
    color: var(--text-color);
    font-weight: 500;
}

.nav-links a:hover { color: var(--secondary-color); }

.menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
    z-index: 1001;
}

.menu-toggle .bar {
    width: 25px;
    height: 3px;
    background-color: var(--primary-color);
    transition: all 0.3s ease-in-out;
    border-radius: 3px;
}

.menu-toggle.active .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.menu-toggle.active .bar:nth-child(2) { opacity: 0; }
.menu-toggle.active .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }


/* =========================================
   Compact Header & Centered Ministry Bar
========================================= */
header {
    background: linear-gradient(135deg, var(--primary-color), #1E3A8A);
    color: #ffffff;
    padding: 35px 20px;
    border-bottom: 6px solid var(--secondary-color); /* Vibrant Saffron bottom border */
    
    /* Flexbox guarantees absolute centering */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

header h1 { 
    font-size: 1.8rem; 
    margin-bottom: 10px; 
    font-weight: 700;
    line-height: 1.3;
}

/* Style for the Hindi text portion inside the title */
header h1 .hindi-title {
    display: block;
    font-size: 1.3rem;
    font-weight: 600;
    opacity: 0.95;
    margin-top: 4px;
}

/* The Beautiful Proper Centered Color Bar for the Ministry */
.ministry-color-bar {
    display: inline-block;
    background: rgba(234, 88, 12, 0.2); /* Saffron-tinted background bar */
    border: 1px solid rgba(234, 88, 12, 0.5); /* Matching clean border */
    color: #ffedd5; /* Warm, highly readable light text */
    padding: 8px 22px;
    border-radius: 6px; /* Clean professional shape */
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.3px;
    margin-top: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* =========================================
   Main Container & Typography
========================================= */
.container {
    max-width: 1100px;
    margin: 40px auto;
    background-color: var(--surface-color);
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
}

h2 {
    color: var(--primary-color);
    font-size: 1.6rem;
    margin-top: 40px;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--border-color);
}

h3 {
    color: var(--primary-color);
    font-size: 1.2rem;
    margin-top: 25px;
    margin-bottom: 15px;
}

p { margin-bottom: 15px; text-align: justify; }
ul, ol { margin-bottom: 20px; margin-left: 20px; }
li { margin-bottom: 8px; }

/* =========================================
   Service Grids & Detailed Cards
========================================= */
.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 15px;
    margin-bottom: 25px;
}

.card {
    background: var(--bg-color);
    padding: 25px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
}

/* Specific Tool Cards (Restored from your embed) */
.tool-card {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    padding: 15px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: var(--surface-color);
    text-decoration: none;
    transition: all 0.2s ease;
}

.tool-card:hover {
    border-color: var(--accent-color);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.1);
}

.tool-card .icon {
    font-size: 24px;
    line-height: 1;
}

.tool-card .details b {
    display: block;
    color: var(--primary-color);
    font-size: 1rem;
    margin-bottom: 3px;
}

.tool-card .details span {
    font-size: 0.85rem;
    color: var(--light-text);
}

/* Action Strips (For Tax & Challan) */
.action-strip {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 20px;
    border-radius: 8px;
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    border-left: 5px solid var(--accent-color);
    text-decoration: none;
    margin-bottom: 10px;
    transition: all 0.2s ease;
}

.action-strip.danger { border-left-color: var(--danger-color); background: #FEF2F2; }
.action-strip.success { border-left-color: var(--success-color); background: #F0FDF4; }
.action-strip.warning { border-left-color: var(--secondary-color); background: #FFF7ED; }

.action-strip:hover { transform: translateX(5px); background: var(--surface-color); box-shadow: 0 4px 10px rgba(0,0,0,0.05); }

.action-strip .icon { font-size: 24px; }
.action-strip .details b { display: block; color: var(--primary-color); font-size: 1rem; }
.action-strip .details span { font-size: 0.85rem; color: var(--light-text); }
.action-strip .arrow { margin-left: auto; color: var(--light-text); font-size: 1.5rem; }

/* Quick Pills (Helplines & Shortcuts) */
.pills-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
}

.pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 50px;
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--primary-color);
    text-decoration: none;
    transition: all 0.2s ease;
}

.pill:hover { background: var(--accent-color); color: #fff; border-color: var(--accent-color); }
.pill.primary { background: var(--primary-color); color: #fff; }
.pill.primary:hover { background: var(--accent-color); }

/* Feature Image */
.feature-image {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    margin-bottom: 20px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

/* =========================================
   Steps, Tables & FAQs
========================================= */
.steps-container {
    background-color: var(--step-bg);
    padding: 25px;
    border-radius: 8px;
    border-left: 5px solid var(--secondary-color);
    margin-bottom: 20px;
}

.steps-container ol { list-style-type: none; margin-left: 0; counter-reset: step-counter; }
.steps-container li { position: relative; margin-bottom: 15px; padding-left: 40px; }
.steps-container li::before {
    counter-increment: step-counter;
    content: counter(step-counter);
    position: absolute;
    left: 0; top: 0;
    background-color: var(--primary-color);
    color: white;
    width: 28px; height: 28px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 0.9rem; font-weight: bold;
}

.table-responsive { overflow-x: auto; margin-bottom: 30px; }
table { width: 100%; border-collapse: collapse; margin-top: 10px; }
th, td { padding: 12px 15px; border: 1px solid var(--border-color); text-align: left; font-size: 0.95rem; }
th { background-color: var(--primary-color); color: white; white-space: nowrap; }
tr:nth-child(even) { background-color: var(--step-bg); }
tr:hover { background-color: #e2e8f0; }

details {
    background-color: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    margin-bottom: 10px;
    padding: 15px;
}
summary { font-size: 1.05rem; font-weight: 600; cursor: pointer; color: var(--primary-color); outline: none; list-style: none; position: relative; padding-right: 20px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: '+'; position: absolute; right: 0; top: 50%; transform: translateY(-50%); font-size: 1.5rem; color: var(--secondary-color); }
details[open] summary::after { content: '-'; }
details p { margin-top: 15px; margin-bottom: 0; color: var(--light-text); border-top: 1px solid var(--border-color); padding-top: 10px; }

/* =========================================
   Footer Styling
========================================= */
footer { background-color: var(--footer-bg); color: #cbd5e1; padding: 40px 20px 20px; margin-top: 50px; }
.footer-container { max-width: 1100px; margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 30px; margin-bottom: 30px; }
.footer-col h4 { color: #ffffff; font-size: 1.2rem; margin-bottom: 15px; border-bottom: 2px solid var(--secondary-color); display: inline-block; padding-bottom: 5px; }
.footer-col ul { list-style: none; margin-left: 0; }
.footer-col ul li { margin-bottom: 10px; }
.footer-col a { color: #cbd5e1; }
.footer-col a:hover { color: var(--secondary-color); }
.footer-bottom { text-align: center; border-top: 1px solid #334155; padding-top: 20px; font-size: 0.9rem; }

/* =========================================
   Responsive Design (Mobile)
========================================= */
@media (max-width: 768px) {
    .menu-toggle { display: flex; }
    .nav-links {
        flex-direction: column; position: absolute; top: 60px; left: -100%;
        width: 100%; background-color: var(--surface-color); text-align: center;
        transition: left 0.3s ease-in-out; box-shadow: 0 10px 15px rgba(0,0,0,0.1); padding: 20px 0;
    }
    .nav-links.active { left: 0; }
    .nav-links li { margin: 15px 0; }
    header { padding: 40px 15px; }
    header h1 { font-size: 1.8rem; }
    .container { padding: 20px; margin: 20px 10px; }
    .grid-2, .grid-3 { grid-template-columns: 1fr; gap: 15px; }
    .steps-container li { padding-left: 35px; }
}
/* =========================================
   Small to Medium Image Styling
========================================= */
.medium-image {
    max-width: 400px; /* Keeps it small-to-medium on desktop */
    width: 100%;       /* Makes it responsive on mobile screens */
    height: auto;
    border-radius: 8px;
    margin: 15px 0;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    display: block;
}