/* ============================================
   M-SHWARI LOAN CALCULATOR CSS
   Page-Specific Styles
   ============================================ */

/* HERO SECTION */
.mshwari-hero {
    position: relative;
    width: 100%;
    padding-top: 3rem;
    padding-bottom: 60px;
    overflow: hidden;
}

.mshwari-hero__background {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #00361e 0%, #004526 50%, #06613a 100%);
    z-index: -2;
}

.mshwari-hero__background::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 30%, rgba(100, 150, 255, 0.12), transparent 40%),
        radial-gradient(circle at 80% 60%, rgba(255, 255, 255, 0.06), transparent 35%);
    z-index: 1;
}

.mshwari-hero__header {
    position: relative;
    text-align: center;
    color: #fff;
    display: grid;
    gap: 1rem;
    margin-bottom: 2rem;
    z-index: 1;
}

.mshwari-hero__title {
    font-size: 3.3rem;
    letter-spacing: -0.018em;
    margin: 0;
    color: #ffffff !important;
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.05;
    font-weight: 900;
    text-transform: uppercase;
    display: inline-block;
    transform: rotate(-0.6deg) skewY(-1deg);
}

.mshwari-hero__subtitle-main {
    font-size: 1.5rem;
    letter-spacing: -0.02em;
    margin: 0;
    color: rgba(255, 255, 255, 0.95);
    line-height: 1.3;
    font-weight: 600;
}

.mshwari-hero__highlight {
    color: #f59e0b;
    font-weight: 800;
}

.mshwari-hero__subtitle {
    max-width: 900px;
    margin: 0 auto;
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.05rem;
    line-height: 1.6;
}

@media (min-width: 1024px) {
    .mshwari-hero__title {
        font-size: 3rem;
    }

    .mshwari-hero__subtitle-main {
        font-size: 1.85rem;
    }
}

.mshwari-hero__wave {
    position: absolute;
    bottom: -20px;
    left: 0;
    width: 100%;
    height: 220px;
    z-index: 0;
}

.mshwari-hero__wave svg {
    width: 100%;
    height: 100%;
    display: block;
}

/* CALCULATOR BOARD */
.mshwari-calc-board {
    position: relative;
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    background: #fff;
    border-radius: 1.25rem;
    box-shadow: 0 35px 90px rgba(0, 0, 0, 0.28), 0 10px 26px rgba(0, 0, 0, 0.14);
    padding: 2rem;
    display: grid;
    gap: 1.5rem;
    color: #1f2937;
    z-index: 1;
    transform: translateY(3rem);
}

@media (min-width: 1024px) {
    .mshwari-calc-board {
        max-width: 1260px;
        padding: 2.5rem;
    }
}

.mshwari-calc-title {
    margin: 0 0 0.5rem;
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: -0.01em;
    color: #004526;
    text-align: center;
    text-decoration: underline wavy #004526;
    text-decoration-thickness: 1.25px;
    text-underline-offset: 4px;
    display: inline-block;
}

.mshwari-loan-selector {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    width: 100%;
    justify-items: center;
}

@media (max-width: 640px) {
    .mshwari-loan-selector {
        grid-template-columns: 1fr;
    }
}

.mshwari-loan-pill {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    border-radius: 0.75rem;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    background: #f3f4f6;
    border: 1.5px solid #d1d5db;
    color: #1f2937;
    font-weight: 600;
    width: 100%;
}

.mshwari-loan-pill input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.mshwari-loan-pill span {
    font-size: 0.9rem;
}

.mshwari-loan-pill:hover {
    border-color: #004526;
    background: rgba(0, 69, 38, 0.06);
    transform: translateY(-1px);
}

.mshwari-loan-pill:has(input:checked) {
    border-color: #004526;
    background: rgba(0, 69, 38, 0.1);
    box-shadow: 0 4px 12px rgba(0, 69, 38, 0.15);
    color: #004526;
    font-weight: 700;
}

.mshwari-calc-input-group {
    display: grid;
    gap: 1rem;
    align-items: center;
}

@media (min-width: 768px) {
    .mshwari-calc-input-group {
        grid-template-columns: 1fr 1fr auto;
        align-items: end;
    }
}

.mshwari-calc-input {
    display: grid;
    gap: 0.5rem;
}

.mshwari-calc-input label {
    font-weight: 700;
    color: #1f2937;
    font-size: 0.9rem;
    display: block;
    text-align: left;
}

.mshwari-calc-input input {
    width: 100%;
    padding: 0.875rem 1.125rem;
    border-radius: 0.75rem;
    border: 1px solid #d1d5db;
    background: #f9fafb;
    color: #1f2937;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.mshwari-calc-input input:focus {
    outline: none;
    border-color: #004526;
    box-shadow: 0 0 0 3px rgba(0, 69, 38, 0.12);
}

.mshwari-calc-input input::placeholder {
    color: #9ca3af;
    font-weight: 500;
}

.mshwari-input-hint {
    font-size: 0.75rem;
    color: #9ca3af;
    text-align: left;
    margin-top: 4px;
}

.mshwari-calc-submit {
    width: 100%;
    padding: 0.875rem 1.5rem;
    border-radius: 0.75rem;
    border: none;
    background: #004526;
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 8px 22px rgba(0, 69, 38, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    height: 44px;
}

@media (min-width: 768px) {
    .mshwari-calc-submit {
        width: auto;
        min-width: 160px;
    }
}

.mshwari-calc-submit:hover {
    background: #003d1f;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 69, 38, 0.25);
}

.mshwari-calc-submit:active {
    transform: translateY(0);
}

/* RESULTS */
.mshwari-results {
    display: grid;
    gap: 1.5rem;
    margin-top: 2rem;
}

.mshwari-result-card {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 1rem;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.mshwari-result-header {
    text-align: center;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e5e7eb;
}

.mshwari-result-title {
    font-size: 1.25rem;
    font-weight: 800;
    color: #004526;
    margin: 0;
}

.mshwari-result-details {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.mshwari-result-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #e5e7eb;
}

.mshwari-result-row:last-child {
    border-bottom: none;
}

.mshwari-result-row span {
    font-size: 0.9rem;
    color: #6b7280;
    font-weight: 500;
}

.mshwari-result-row strong {
    font-size: 1rem;
    color: #1f2937;
    font-weight: 700;
}

.mshwari-result-row--highlight {
    background: rgba(0, 69, 38, 0.05);
    padding: 0.75rem;
    border-radius: 0.5rem;
    border: 1px solid rgba(0, 69, 38, 0.2);
}

.mshwari-limits__heading {
    text-align: center;
    font-size: 2rem;
    font-weight: 800;
    color: #1f2937;
    margin-bottom: 3rem;
}

.mshwari-limits__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.mshwari-limit-card {
    background: #ffffff;
    border: 2px solid #86efac;
    border-radius: 1rem;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
}

.mshwari-limit-card:hover {
    box-shadow: 0 12px 32px rgba(0, 69, 38, 0.15);
    transform: translateY(-4px);
    border-color: #004526;
}

.mshwari-limit-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #004526 0%, #006837 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    color: #ffffff;
    font-size: 1.5rem;
}

.mshwari-limit-card h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0 0 0.75rem;
}

.mshwari-limit-value {
    font-size: 1.75rem;
    font-weight: 900;
    color: #004526;
    margin: 0.5rem 0;
}

.mshwari-limit-description {
    font-size: 0.9rem;
    color: #6b7280;
    line-height: 1.5;
    margin: 0;
}

/* FEATURES SECTION */
.mshwari-features {
    padding: 4rem 0;
    background: #f9fbf7;
}

.mshwari-features-heading {
    text-align: center;
    font-size: 2rem;
    font-weight: 800;
    color: #1f2937;
    margin-bottom: 3rem;
}

.mshwari-features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.mshwari-feature-card {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 1rem;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
}

.mshwari-feature-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    transform: translateY(-4px);
    border-color: #004526;
}

.mshwari-feature-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #004526 0%, #006837 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    color: #ffffff;
    font-size: 1.5rem;
}

.mshwari-feature-card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0 0 0.75rem;
}

.mshwari-feature-card p {
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
}

/* RATE TABLE SECTION */
.mshwari-rate-table-section {
    padding: 4rem 0;
    background: #f9fbf7;
}

.mshwari-rate-table-heading {
    text-align: center;
    margin-bottom: 2rem;
}

.mshwari-rate-table-heading h2 {
    font-size: 2rem;
    font-weight: 800;
    color: #1f2937;
    margin-bottom: 0.75rem;
}

.mshwari-rate-table-heading p {
    font-size: 1.05rem;
    color: #6b7280;
}

.mshwari-rate-toggle-group {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.mshwari-rate-toggle {
    padding: 0.75rem 1.5rem;
    background: #ffffff;
    border: 2px solid #e5e7eb;
    border-radius: 0.5rem;
    font-weight: 600;
    color: #6b7280;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mshwari-rate-toggle:hover {
    border-color: #004526;
    color: #004526;
}

.mshwari-rate-toggle.active {
    background: #004526;
    border-color: #004526;
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 69, 38, 0.3);
}

.mshwari-rate-table-wrapper {
    background: #ffffff;
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    overflow-x: auto;
}

.mshwari-rate-table {
    width: 100%;
    border-collapse: collapse;
}

.mshwari-rate-table thead {
    background: #f9fafb;
}

.mshwari-rate-table th {
    padding: 1rem;
    text-align: left;
    font-weight: 700;
    color: #374151;
    border-bottom: 2px solid #e5e7eb;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.mshwari-rate-table td {
    padding: 1rem;
    border-bottom: 1px solid #e5e7eb;
    color: #4b5563;
}

.mshwari-rate-table tbody tr:hover {
    background: #f9fafb;
}

/* ARTICLE SECTION */
.mshwari-article-section {
    background: #f5f5f0;
    padding: 4rem 0;
}

.mshwari-article {
    max-width: 900px;
    margin: 0 auto;
    background: #fffef8;
    position: relative;
    padding: 3rem 3rem 3rem 5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1), 0 8px 24px rgba(0, 0, 0, 0.08);
    border-radius: 4px;

    /* Notebook paper texture */
    background-image:
        linear-gradient(transparent, transparent 31px, #e0dfd8 31px, #e0dfd8 32px),
        linear-gradient(90deg, #004526 0, #004526 2px, transparent 2px);
    background-size: 100% 32px, 100% 100%;
    background-position: 0 40px, 0 0;
}

/* Green margin line */
.mshwari-article::before {
    content: '';
    position: absolute;
    left: 4rem;
    top: 0;
    bottom: 0;
    width: 2px;
    background: #004526;
    opacity: 0.6;
}

.mshwari-article-header {
    margin-bottom: 2.5rem;
    padding-bottom: 1.5rem;
    border-bottom: none;
    position: relative;
}

.mshwari-article-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: #1a1a1a;
    margin: 0 0 1rem;
    line-height: 1.3;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.mshwari-article-body {
    font-size: 1.0625rem;
    line-height: 1.75;
    color: #374151;
    margin: 0 0 1rem;
}

.mshwari-article-body p {
    margin: 0 0 1.5rem;
}

.mshwari-article-lead {
    font-size: 1.25rem;
    font-weight: 500;
    color: #111827;
    line-height: 1.6;
    margin-bottom: 2rem;
}

.mshwari-article-body h3 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #111827;
    margin: 2.5rem 0 1.25rem;
    line-height: 1.3;
}

.mshwari-article-body h4 {
    font-size: 1.35rem;
    font-weight: 600;
    color: #111827;
    margin: 2rem 0 1rem;
    line-height: 1.4;
}

.mshwari-article-body ul,
.mshwari-article-body ol {
    margin: 0 0 1.5rem;
    padding-left: 1.75rem;
}

.mshwari-article-body li {
    margin-bottom: 0.75rem;
    line-height: 1.7;
}

.mshwari-article-body li strong {
    color: #111827;
    font-weight: 600;
}

.mshwari-article-body strong {
    color: #111827;
    font-weight: 600;
}

.mshwari-article-callout {
    padding: 1.25rem 1.5rem;
    border-radius: 0.75rem;
    margin: 2rem 0;
    border-left: 4px solid;
}

.mshwari-article-callout p {
    margin: 0;
}

.mshwari-article-callout--success {
    background: #f0fdf4;
    border-color: #10b981;
    color: #065f46;
}

.mshwari-article-callout--success strong {
    color: #047857;
}

.mshwari-article-callout--warning {
    background: #fffbeb;
    border-color: #f59e0b;
    color: #92400e;
}

.mshwari-article-callout--warning strong {
    color: #b45309;
}

@media (max-width: 768px) {
    .mshwari-article-section {
        padding: 2rem 1rem;
    }

    .mshwari-article {
        padding: 2rem 1.5rem 2rem 3.5rem;
        background-size: 100% 28px, 100% 100%;
        background-position: 0 32px, 0 0;
    }

    .mshwari-article::before {
        left: 3rem;
    }

    .mshwari-article-title {
        font-size: 1.875rem;
    }

    .mshwari-article-body {
        font-size: 1rem;
    }

    .mshwari-article-lead {
        font-size: 1.125rem;
    }

    .mshwari-article-body h3 {
        font-size: 1.5rem;
        margin: 2rem 0 1rem;
    }

    .mshwari-article-body h4 {
        font-size: 1.25rem;
        margin: 1.5rem 0 0.75rem;
    }

    .mshwari-article-callout {
        padding: 1rem;
        margin: 1.5rem 0;
    }
}

/* LIMITS SECTION */
.mshwari-limits-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, #004526 0%, #002d19 100%);
    position: relative;
    overflow: hidden;
}

.mshwari-limits-heading {
    text-align: center;
    margin-bottom: 3rem;
}

.mshwari-limits-heading h2 {
    font-size: 2rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 0.75rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.mshwari-limits-heading p {
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.9);
}

.mshwari-limits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.mshwari-limit-card {
    background: #ffffff;
    border: 2px solid #86efac;
    border-radius: 1rem;
    padding: 2rem;
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
    transition: all 0.3s ease;
}

.mshwari-limit-card--primary {
    border-color: #86efac;
}

.mshwari-limit-card:hover {
    box-shadow: 0 12px 32px rgba(0, 69, 38, 0.15);
    transform: translateY(-4px);
    border-color: #004526;
}

.mshwari-limit-card__icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #004526 0%, #006837 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.mshwari-limit-card__content {
    flex: 1;
    text-align: left;
}

.mshwari-limit-card__content h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0 0 0.5rem;
}

.mshwari-limit-card__value {
    font-size: 1.75rem;
    font-weight: 900;
    color: #004526;
    margin: 0.5rem 0;
}

.mshwari-limit-card__description {
    font-size: 0.9rem;
    color: #6b7280;
    line-height: 1.5;
    margin: 0;
}

/* FAQ SECTION */
.mshwari-faq {
    padding: 4rem 0;
    background: #ffffff;
}

.mshwari-faq-heading {
    text-align: center;
    font-size: 2rem;
    font-weight: 800;
    color: #1f2937;
    margin-bottom: 3rem;
}

.mshwari-faq-list {
    max-width: 900px;
    margin: 0 auto;
}

.mshwari-faq-item {
    background: #f9fbf7;
    border: 2px solid #e5e7eb;
    border-radius: 0.75rem;
    margin-bottom: 1rem;
    overflow: hidden;
    transition: all 0.3s ease;
}

.mshwari-faq-item:hover {
    border-color: #004526;
}

.mshwari-faq-item[open] {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    border-color: #004526;
}

.mshwari-faq-question {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    background: transparent;
    border: none;
    cursor: pointer;
    text-align: left;
    transition: all 0.3s ease;
}

.mshwari-faq-question:hover {
    background: #f0fdf4;
}

.mshwari-faq-item[open] .mshwari-faq-question {
    background: #f0fdf4;
}

.mshwari-faq-question span {
    font-size: 1.05rem;
    font-weight: 700;
    color: #1f2937;
    flex: 1;
    padding-right: 1rem;
}

.mshwari-faq-question i {
    font-size: 1.25rem;
    font-weight: 700;
    color: #004526;
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.mshwari-faq-item[open] .mshwari-faq-question i {
    transform: rotate(180deg);
}

.mshwari-faq-answer {
    padding: 0 1.5rem 1.5rem;
    color: #4b5563;
    line-height: 1.7;
    font-size: 0.95rem;
}

.mshwari-faq-answer p {
    margin: 0;
}

/* RESPONSIVE */
@media (max-width: 768px) {
    .mshwari-hero__title {
        font-size: 2rem;
    }

    .mshwari-hero__subtitle-main {
        font-size: 1.25rem;
    }

    .mshwari-calc-board {
        padding: 1.5rem;
        transform: translateY(2rem);
    }

    .mshwari-limits-grid {
        grid-template-columns: 1fr;
    }
}