/* Centralized Variables */
:root {
    --color-primary: #218888;
    --color-primary-dark: #1a6b6b;
    --color-primary-light: #32b4b4;
    --color-secondary: #f5a623;
    --color-text-dark: #1a202c;
    --color-text-light: #4a5568;
    --color-bg-light: #f7fafc;
    --color-bg-white: #ffffff;
    --color-border: #e2e8f0;
    --color-success: #48bb78;
    --color-error: #f56565;
    --color-warning: #ed8936;
    --space-4: 4px;
    --space-8: 8px;
    --space-12: 12px;
    --space-16: 16px;
    --space-24: 24px;
    --space-32: 32px;
    --radius-base: 8px;
    --radius-lg: 12px;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 20px rgba(0, 0, 0, 0.15);
}

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: var(--color-bg-light);
    color: var(--color-text-dark);
    line-height: 1.6;
}

/* UX Focus Mode */
body.dimmed::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.35);
    z-index: 1000;
    pointer-events: none;
    transition: opacity 0.3s;
}

body.dimmed .bill-checker {
    position: relative;
    z-index: 1001;
}

/* Bill Checker Container */
.bill-checker {
    background: var(--color-bg-white);
    padding: var(--space-32) var(--space-24);
    margin: -60px var(--space-24) var(--space-32);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    position: relative;
}

.bill-checker h2 {
    font-size: 24px;
    margin-bottom: var(--space-16);
    color: var(--color-text-dark);
}

/* Recent Meters (Saved List) */
.recent-meters {
    margin-bottom: 24px;
    display: none;
    background: #f8fafc;
    border-radius: 8px;
    padding: 12px;
    border: 1px solid #e2e8f0;
}

.recent-header {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--color-text-light);
}

.recent-header-urdu {
    font-family: 'Noto Nastaliq Urdu', serif;
    font-size: 16px;
    font-weight: normal;
}

.meter-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.meter-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: white;
    padding: 10px 14px;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
    cursor: pointer;
    transition: all 0.2s;
}

.meter-item:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

/* Multi-Color Chip Styles (Light Pastels) */
.meter-color-0 {
    border-left: 4px solid #FFADAD;
    background-color: #FFF0F0;
}

.meter-color-1 {
    border-left: 4px solid #FFD6A5;
    background-color: #FFF8F0;
}

.meter-color-2 {
    border-left: 4px solid #FDFFB6;
    background-color: #FEFFF0;
}

.meter-color-3 {
    border-left: 4px solid #CAFFBF;
    background-color: #F0FFF0;
}

.meter-color-4 {
    border-left: 4px solid #9BF6FF;
    background-color: #F0FDFF;
}

.meter-color-5 {
    border-left: 4px solid #A0C4FF;
    background-color: #F0F6FF;
}

.meter-color-6 {
    border-left: 4px solid #BDB2FF;
    background-color: #F6F4FF;
}

.meter-color-7 {
    border-left: 4px solid #FFC6FF;
    background-color: #FFF0FF;
}

.delete-meter-btn {
    background: #fed7d7;
    border: none;
    color: #c53030;
    font-size: 20px;
    font-weight: bold;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    margin-left: 8px;
    z-index: 10;
    line-height: 1;
}

.delete-meter-btn:hover {
    background: #e53e3e;
    color: white;
    transform: scale(1.1);
}

.meter-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.meter-name {
    font-weight: 600;
    font-size: 15px;
    color: var(--color-text-dark);
}

.meter-details {
    font-size: 13px;
    color: var(--color-text-light);
    display: flex;
    gap: 8px;
    align-items: center;
}

.meter-badge {
    background: rgba(0, 0, 0, 0.05);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: bold;
    color: var(--color-text-light);
}

/* Form Elements */
.form-group {
    margin-bottom: var(--space-24);
}

label {
    display: block;
    margin-bottom: var(--space-8);
    font-weight: 600;
    color: var(--color-text-dark);
    font-size: 14px;
}

input[type="text"],
input[type="email"],
textarea,
select {
    width: 100%;
    padding: var(--space-12) var(--space-16);
    border: 2px solid var(--color-border);
    border-radius: var(--radius-base);
    font-family: inherit;
    font-size: 16px;
    transition: border-color 0.3s;
}

input[type="text"]:focus,
select:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(33, 136, 136, 0.1);
}

.input-hint {
    font-size: 12px;
    color: var(--color-text-light);
    margin-top: var(--space-4);
}

/* Validation */
.input-error {
    border-color: var(--color-error) !important;
    background-color: #fff5f5;
}

.error-message {
    color: var(--color-error);
    font-size: 12px;
    margin-top: 4px;
}

/* Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-card {
    background: white;
    padding: 24px;
    border-radius: 12px;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    transform: scale(0.95);
    transition: transform 0.3s;
}

.modal-overlay.active .modal-card {
    transform: scale(1);
}

.modal-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 16px;
}

.predefined-names {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}

.name-chip {
    padding: 6px 12px;
    background: #edf2f7;
    border-radius: 16px;
    font-size: 13px;
    cursor: pointer;
    transition: 0.2s;
}

.name-chip:hover {
    background: #e2e8f0;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 20px;
}

.btn-text {
    background: none;
    border: none;
    color: #718096;
    cursor: pointer;
    font-weight: 600;
    padding: 8px 16px;
}

.btn-primary,
.cta-secondary {
    background: var(--color-primary);
    color: white;
    padding: var(--space-12) var(--space-24);
    border-radius: var(--radius-base);
    text-decoration: none;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 16px;
}

.btn-primary:hover,
.cta-secondary:hover {
    background: var(--color-primary-dark);
}

/* Trust Line */
.trust-line {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #eee;
    text-align: center;
    font-size: 12px;
    color: #718096;
    line-height: 1.5;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(400px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Media Queries */

/* Navigation */
nav {
    background: var(--color-bg-white);
    box-shadow: var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: var(--space-16) var(--space-24);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 24px;
    font-weight: 700;
    color: var(--color-primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: var(--space-8);
}

.logo::before {
    content: "⚡";
    font-size: 28px;
}

.nav-links {
    display: none;
    list-style: none;
    gap: var(--space-32);
}

.nav-links a {
    text-decoration: none;
    color: var(--color-text-dark);
    font-weight: 500;
    transition: color 0.3s;
}

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

@media (min-width: 768px) {
    .nav-links {
        display: flex;
    }
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    color: white;
    padding: var(--space-32) var(--space-24);
    text-align: center;
    padding-bottom: 80px;
    /* Added extra padding to account for negative margin of bill checker */
}

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

.hero h1 {
    font-size: clamp(28px, 5vw, 48px);
    margin-bottom: var(--space-16);
    font-weight: 700;
    line-height: 1.2;
}

.hero p {
    font-size: clamp(16px, 2vw, 20px);
    margin-bottom: var(--space-32);
    opacity: 0.95;
}

.cta-primary {
    display: inline-block;
    background: var(--color-secondary);
    color: white;
    padding: var(--space-12) var(--space-24);
    border-radius: var(--radius-lg);
    text-decoration: none;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 16px;
}

.cta-primary:hover {
    background: #e89a1d;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Info Cards Section */
.info-section {
    max-width: 1200px;
    margin: var(--space-32) auto;
    padding: 0 var(--space-24);
}

.section-title {
    font-size: 32px;
    margin-bottom: var(--space-32);
    text-align: center;
    color: var(--color-text-dark);
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--space-24);
    margin-bottom: var(--space-32);
}

.card {
    background: var(--color-bg-white);
    padding: var(--space-24);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    border-left: 4px solid var(--color-primary);
    transition: all 0.3s;
    animation: fadeIn 0.6s ease-out forwards;
}

.card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-4px);
}

.card-icon {
    font-size: 32px;
    margin-bottom: var(--space-12);
}

.card h3 {
    font-size: 20px;
    margin-bottom: var(--space-12);
    color: var(--color-text-dark);
}

.card p {
    font-size: 14px;
    color: var(--color-text-light);
    line-height: 1.6;
}

/* FAQ Section */
.faq-section {
    max-width: 900px;
    margin: var(--space-32) auto;
    padding: 0 var(--space-24);
}

.faq-item {
    background: var(--color-bg-white);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-base);
    margin-bottom: var(--space-16);
    overflow: hidden;
}

.faq-question {
    padding: var(--space-16) var(--space-24);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    background: var(--color-bg-light);
    transition: background 0.3s;
    user-select: none;
}

.faq-question:hover {
    background: #f0f4f8;
}

.faq-question::after {
    content: "▼";
    font-size: 12px;
    transition: transform 0.3s;
}

.faq-item.active .faq-question::after {
    transform: rotate(180deg);
}

.faq-answer {
    display: none;
    padding: var(--space-16) var(--space-24);
    background: var(--color-bg-white);
    color: var(--color-text-light);
    border-top: 1px solid var(--color-border);
    line-height: 1.8;
}

.faq-item.active .faq-answer {
    display: block;
}

/* Services Section */
.services {
    background: linear-gradient(135deg, #f7fafc 0%, #edf2f7 100%);
    padding: var(--space-32) var(--space-24);
}

.services-container {
    max-width: 1200px;
    margin: 0 auto;
}

.features-list {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-24);
}

.features-list li {
    display: flex;
    gap: var(--space-12);
    align-items: flex-start;
}

.features-list li::before {
    content: "✓";
    color: var(--color-success);
    font-weight: bold;
    font-size: 20px;
    margin-top: 2px;
    flex-shrink: 0;
}

/* Footer */
footer {
    background: #1a202c;
    color: #a0aec0;
    padding: var(--space-32) var(--space-24);
    text-align: center;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: var(--space-24);
    margin-bottom: var(--space-24);
    flex-wrap: wrap;
}

.footer-links a {
    color: #a0aec0;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    border-top: 1px solid #2d3748;
    padding-top: var(--space-24);
    font-size: 14px;
}

/* Responsive Overrides not covered in base */
@media (max-width: 768px) {
    .nav-container {
        padding: var(--space-12) var(--space-16);
    }

    .hero {
        padding: var(--space-24) var(--space-16);
        padding-bottom: 60px;
    }

    .section-title {
        font-size: 24px;
    }

    .btn-group {
        grid-template-columns: 1fr;
    }
}

/* Bill Result Component */
.bill-result {
    margin-top: 1.5rem;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e2e8f0;
}

.ref-label {
    font-size: 0.875rem;
    color: #64748b;
    display: block;
}

.ref-value {
    font-family: 'Courier New', monospace;
    font-weight: 700;
    font-size: 1.1rem;
    color: #1e293b;
    letter-spacing: 1px;
}

.close-result {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #94a3b8;
    cursor: pointer;
    line-height: 1;
    padding: 0 0.5rem;
}

.close-result:hover {
    color: #ef4444;
}

.bill-details-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.detail-item {
    background: white;
    padding: 0.75rem;
    border-radius: 8px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.detail-item.prime {
    grid-column: 1 / -1;
    background: #f0f9ff;
    border: 1px solid #bae6fd;
    text-align: center;
}

.detail-item label {
    display: block;
    font-size: 0.75rem;
    color: #64748b;
    margin-bottom: 0.25rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.detail-item .value {
    font-weight: 600;
    color: #0f172a;
    font-size: 1rem;
}

.detail-item .amount-value {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--primary-color, #0d9488);
}

.detail-item .due-date {
    font-size: 0.875rem;
    color: #ef4444;
    font-weight: 500;
    margin-top: 0.25rem;
}

.result-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.btn-primary.full-width {
    width: 100%;
    justify-content: center;
}

.btn-text.full-width {
    width: 100%;
    text-align: center;
}

/* Mobile Adjustments */
@media (max-width: 480px) {
    .bill-details-grid {
        grid-template-columns: 1fr;
    }
}


/* Inline Save Group */
.inline-save-group {
    margin: 1rem 0;
    padding-top: 1rem;
    border-top: 1px dashed #e2e8f0;
}

.inline-save-group label {
    display: block;
    font-size: 0.85rem;
    color: #64748b;
    margin-bottom: 0.5rem;
}

.save-input-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: center;
}

.save-input-wrapper input {
    flex: 1;
    min-width: 200px;
    padding: 0.5rem 0.75rem;
    border: 1px solid #cbd5e0;
    border-radius: 6px;
    font-size: 0.9rem;
}

.chip-group {
    display: flex;
    gap: 0.5rem;
}

.name-chip {
    background: #e2e8f0;
    border: none;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    font-size: 0.75rem;
    color: #4a5568;
    cursor: pointer;
    transition: all 0.2s;
}

.name-chip:hover {
    background: #cbd5e0;
    color: #2d3748;
}

/* Cleanup Modal Styles (Optional Override) */
.modal-overlay {
    display: none !important;
}


/* Global Button Group Alignment */
.btn-group {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 1rem;
    width: 100%;
}


/* Home Page Refresh */
.home {
    background: var(--color-bg-light);
    color: var(--color-text-dark);
    font-size: 17px;
    line-height: 1.7;
}

.home nav {
    background: var(--color-bg-white);
    border-bottom: 1px solid var(--color-border);
}

.home .logo::before {
    content: "⚡";
    font-size: 24px;
}

.home .hero {
    background: linear-gradient(120deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    color: #f8fafc;
    padding: 48px 24px 72px;
}

.home .bill-form-section {
    padding: 0 24px 64px;
    margin-top: -40px;
}

.home .bill-form-section .section-shell {
    max-width: 1100px;
    margin: 0 auto;
}

.home .bill-form-section .hero-card {
    max-width: 860px;
    margin: 0 auto;
}

.home .bill-form-section .recent-meters {
    margin-top: 12px;
    margin-bottom: 20px;
}

.home .hero-shell {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 32px;
    align-items: center;
}

.home .hero-copy {
    text-align: center;
    max-width: 820px;
    margin: 0 auto;
}

@media (min-width: 900px) {
    .home .hero-shell {
        max-width: 980px;
    }
}

.home .hero-copy h1 {
    font-size: clamp(32px, 4vw, 48px);
    line-height: 1.2;
    margin-bottom: 16px;
}

.home .lead {
    font-size: 1.05rem;
    line-height: 1.8;
    margin-bottom: 16px;
    color: rgba(255, 255, 255, 0.95);
}

.home .hero-links {
    margin-bottom: 20px;
    font-size: 0.95rem;
    display: inline-flex;
    justify-content: center;
}

.home .hero-links a {
    color: #fef3c7;
    text-decoration: underline;
}

.home .hero-actions {
    margin-bottom: 16px;
    display: flex;
    justify-content: center;
}

.home .trust-badges {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 0;
    margin: 0;
    font-size: 0.9rem;
    justify-content: center;
}

.home .trust-badges li {
    background: rgba(255, 255, 255, 0.15);
    padding: 6px 12px;
    border-radius: 999px;
}

.home .hero-card {
    background: #ffffff;
    border-radius: 20px;
    padding: 24px;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.2);
    color: var(--color-text-dark);
}

.home .form-card h2 {
    font-size: 1.5rem;
    margin-bottom: 6px;
}

.home .card-subtitle {
    color: var(--color-text-light);
    margin-bottom: 20px;
}

.home .bill-checker {
    background: transparent;
    padding: 0;
    margin: 0;
    box-shadow: none;
    max-width: 100%;
}

.home .primary-fields {
    display: grid;
    gap: 18px;
}

.home .field label {
    font-size: 1rem;
    font-weight: 600;
}

.home .label-urdu,
.home .hint-urdu {
    display: inline-block;
    font-size: 0.9rem;
    color: var(--color-text-light);
    font-weight: 500;
    font-family: 'Noto Naskh Arabic', 'Segoe UI', Arial, sans-serif;
}

.home .hint-urdu {
    margin-left: 4px;
}

.home input[type="text"],
.home select {
    font-size: 1.05rem;
    padding: 14px 16px;
    border-radius: 12px;
    border: 2px solid var(--color-border);
    background: #ffffff;
}

.home input[type="text"]:focus,
.home select:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(33, 136, 136, 0.2);
}

.home .form-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.home .btn-large {
    width: 100%;
    font-size: 1.05rem;
}

.home .btn-muted {
    background: #e2e8f0;
    color: #1f2937;
    border: none;
    border-radius: 999px;
    padding: 12px 20px;
    font-weight: 600;
    cursor: pointer;
}

.home .advanced-toggle {
    background: none;
    border: none;
    color: var(--color-primary-dark);
    font-weight: 600;
    margin-top: 12px;
    cursor: pointer;
    text-decoration: underline;
    font-size: 0.95rem;
}

.home .advanced-panel {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px dashed var(--color-border);
}

.home .advanced-panel[hidden] {
    display: none;
}

.home .recent-meters {
    background: #f8fafc;
    border-radius: 12px;
    border: 1px solid var(--color-border);
}

.home .inline-save-group label {
    font-size: 0.95rem;
}

.home .trust-line {
    text-align: left;
    font-size: 0.85rem;
    color: var(--color-text-light);
}

.home .section {
    padding: 64px 24px;
}

.home .section-contrast {
    background: #f1f5f9;
}

.home .section-shell {
    max-width: 1100px;
    margin: 0 auto;
}

.home .section-head h2 {
    font-size: clamp(1.8rem, 3vw, 2.3rem);
    margin-bottom: 12px;
}

.home .company-list {
    display: grid;
    gap: 24px;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    background: #ffffff;
    border-radius: 16px;
    padding: 24px;
    box-shadow: var(--shadow-sm);
}

.home .company-list a,
.home .company-card a {
    color: var(--color-primary-dark);
    text-decoration: none;
    font-weight: 600;
}

.home .company-grid {
    display: grid;
    gap: 24px;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.home .company-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 24px;
    box-shadow: var(--shadow-sm);
}

.home .company-card.highlight {
    background: var(--color-primary-dark);
    color: #ffffff;
}

.home .feature-grid,
.home .steps-grid {
    display: grid;
    gap: 20px;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.home .feature-card,
.home .step-card {
    background: #ffffff;
    padding: 20px;
    border-radius: 14px;
    box-shadow: var(--shadow-sm);
}

.home .step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--color-primary);
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
    font-weight: 700;
}

.home .bullet-grid {
    list-style: none;
    display: grid;
    gap: 12px 24px;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    padding: 0;
}

.home .bullet-grid li,
.home .popular-grid a {
    background: #ffffff;
    border-radius: 12px;
    padding: 14px 16px;
    box-shadow: var(--shadow-sm);
}

.home .info-columns {
    display: grid;
    gap: 20px;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    align-items: start;
}

.home .popular-grid {
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.home .popular-grid a {
    color: var(--color-text-dark);
    text-decoration: none;
}

.home .callout {
    background: var(--color-primary-dark);
    color: #ffffff;
}

.home .callout-card {
    background: rgba(255, 255, 255, 0.12);
    border-radius: 16px;
    padding: 28px;
    text-align: center;
}

.home .btn.btn-primary {
    background: var(--color-secondary);
    color: #ffffff;
    border-radius: 999px;
    padding: 12px 22px;
    font-size: 1rem;
}

.home .btn.btn-primary:hover {
    background: #e89a1d;
}

@media (max-width: 768px) {
    .home .hero {
        padding: 36px 16px 56px;
    }

    .home .bill-form-section {
        padding: 0 16px 48px;
        margin-top: -32px;
    }

    .home .hero-card {
        padding: 20px;
    }

    .home .form-actions {
        flex-direction: column;
        align-items: stretch;
    }
}


.home .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    border: none;
    cursor: pointer;
}

.home .btn-large {
    min-height: 52px;
    width: 100%;
}


.home .input-hint {
    font-size: 0.9rem;
    color: var(--color-text-light);
}


.home .hero-links {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.home .company-list a:hover,
.home .popular-grid a:hover,
.home .company-card a:hover {
    text-decoration: underline;
}


.home .btn:focus-visible,
.home input[type="text"]:focus-visible,
.home select:focus-visible {
    outline: 3px solid var(--color-secondary);
    outline-offset: 2px;
}


.home .bill-history {
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid var(--color-border);
}

.home .history-header h3 {
    font-size: 1.2rem;
    margin-bottom: 6px;
}

.home .history-grid {
    display: grid;
    gap: 16px;
    margin-top: 16px;
}

.home .history-card {
    border: 1px solid var(--color-border);
    border-radius: 14px;
    padding: 16px;
    background: #ffffff;
    box-shadow: var(--shadow-sm);
}

.home .history-top {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.home .history-title {
    font-weight: 700;
    font-size: 1.05rem;
}

.home .history-sub {
    font-size: 0.9rem;
    color: var(--color-text-light);
}

.home .history-amount {
    text-align: right;
    font-weight: 700;
    color: var(--color-primary-dark);
}

.home .history-amount small {
    display: block;
    font-weight: 500;
    color: var(--color-text-light);
}

.home .history-grid {
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.home .history-actions {
    margin-top: 12px;
}

.home .history-actions .btn {
    width: 100%;
}

.home .history-empty {
    padding: 12px 0;
    color: var(--color-text-light);
}

.home .after-due {
    margin-top: 6px;
    font-size: 0.9rem;
    color: #b45309;
    font-weight: 600;
}

.skip-link {
    position: absolute;
    left: 16px;
    top: -40px;
    background: #111827;
    color: #f9fafb;
    padding: 8px 12px;
    border-radius: 8px;
    text-decoration: none;
    z-index: 2000;
    transition: top 0.2s ease;
}

.skip-link:focus {
    top: 16px;
}


.home .faq-question::after {
    content: "▾";
    font-size: 12px;
}

.home .faq-item.active .faq-question::after {
    transform: rotate(180deg);
}
