/* ==========================================================================
   Wealth Building Financial - Shared Components
   ========================================================================== */

/* Button Styles */
.btn-template-main {
    background: var(--gradient-primary);
    border: 1px solid rgba(15, 23, 42, 0.2);
    color: #fff;
    padding: 14px 30px;
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 0.02em;
    border-radius: var(--radius-sm);
    text-decoration: none;
    display: inline-block;
    transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
    cursor: pointer;
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.18);
}

.btn-template-main:hover {
    filter: brightness(1.05);
    color: #fff;
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.24);
}

.btn-template-main:focus-visible {
    box-shadow: 0 0 0 3px rgba(26, 156, 140, 0.35), 0 12px 30px rgba(15, 23, 42, 0.2);
    outline: none;
}

.btn-template-main.btn-lg {
    padding: 15px 35px;
    font-size: 18px;
}

.btn-outline-primary {
    color: var(--color-primary);
    border: 1px solid var(--color-primary);
    background: transparent;
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.02em;
    border-radius: var(--radius-sm);
    text-decoration: none;
    display: inline-block;
    transition: var(--transition);
}

.btn-outline-primary:hover {
    background-color: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
    text-decoration: none;
}

.btn-block {
    width: 100%;
    margin-bottom: 15px;
}

/* Shared Component Bases */
.service-card,
.calculator-card,
.tool-card,
.report-item,
.guide-card,
.resource-card,
.login-card {
    background: var(--color-surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    margin-bottom: 30px;
    transition: var(--transition);
    height: 100%;
    border: 1px solid var(--color-border);
    position: relative;
    overflow: hidden;
}

.service-card::before,
.calculator-card::before,
.tool-card::before,
.report-item::before,
.guide-card::before,
.resource-card::before,
.login-card::before {
    content: "";
    position: absolute;
    inset: 0 0 auto 0;
    height: 4px;
    background: var(--gradient-cta);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.service-card:hover,
.calculator-card:hover,
.tool-card:hover,
.report-item:hover,
.guide-card:hover,
.resource-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
    border-color: var(--color-secondary);
}

.service-card:hover::before,
.calculator-card:hover::before,
.tool-card:hover::before,
.report-item:hover::before,
.guide-card:hover::before,
.resource-card:hover::before {
    opacity: 1;
}

.service-icon,
.calculator-icon,
.tool-icon,
.resource-icon,
.feature-icon {
    width: 76px;
    height: 76px;
    border-radius: 18px;
    margin: 0 auto 25px;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.08), rgba(26, 156, 140, 0.12));
    border: 1px solid rgba(26, 156, 140, 0.2);
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.service-icon i,
.calculator-icon i,
.tool-icon i,
.resource-icon i,
.feature-icon i {
    font-size: 30px;
    color: var(--color-primary);
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary), var(--color-accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.service-features,
.appointment-card ul,
.info-card ul,
.resource-list,
.security-features,
.benefits-list {
    list-style: none;
    padding: 0;
}

/* Generic Card Components */
.box-simple {
    padding: 30px;
    margin-bottom: 30px;
    background: var(--color-surface);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--color-border);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.box-simple:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--color-secondary);
}

.box-simple .icon {
    text-align: center;
    margin-bottom: 20px;
}

.box-simple a {
    color: inherit;
    text-decoration: none;
}

.box-simple h3,
.box-simple h4 {
    color: var(--color-text);
    margin-bottom: 15px;
}

.box-simple p {
    color: var(--color-text-muted);
    line-height: 1.6;
}

.service-card {
    padding: 40px 30px;
}

.service-icon {
    margin-bottom: 25px;
}

.service-card h3 {
    color: var(--color-text);
    margin-bottom: 20px;
    font-weight: 600;
    text-align: center;
}

.service-card p {
    color: var(--color-text-muted);
    line-height: 1.6;
    margin-bottom: 25px;
    text-align: center;
}

.service-features {
    margin: 0;
}

.service-features li {
    color: var(--color-text-muted);
    padding: 8px 0;
    border-bottom: 1px solid var(--color-border-light);
    position: relative;
    padding-left: 25px;
}

.service-features li:before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--color-secondary);
    font-weight: bold;
}

.service-features li:last-child {
    border-bottom: none;
}

/* Section Styles */
.heading {
    margin-bottom: 50px;
}

.heading h1,
.heading h2 {
    color: var(--color-text);
    margin-bottom: 15px;
    font-weight: 700;
}

.heading .lead {
    color: var(--color-text-muted);
    font-size: 18px;
}

.section-title {
    color: var(--color-text);
    margin-bottom: 40px;
    font-weight: 600;
    position: relative;
    padding-bottom: 15px;
}

.section-title:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--gradient-cta);
}

.section-title.text-center:after {
    left: 50%;
    transform: translateX(-50%);
}

.home-carousel {
    background: var(--gradient-primary);
    position: relative;
    overflow: hidden;
    color: #f8fafc;
    isolation: isolate;
}

.home-carousel::before,
.home-carousel::after {
    content: "";
    position: absolute;
    width: 540px;
    height: 540px;
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
}

.home-carousel::before {
    top: -260px;
    left: -140px;
    background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.28), rgba(255, 255, 255, 0));
    opacity: 0.7;
}

.home-carousel::after {
    bottom: -280px;
    right: -160px;
    background: radial-gradient(circle at 70% 70%, rgba(26, 156, 140, 0.45), rgba(26, 156, 140, 0));
    opacity: 0.75;
}

.home-carousel .dark-mask {
    background: linear-gradient(120deg, rgba(15, 23, 42, 0.78), rgba(15, 23, 42, 0.35));
    opacity: 1;
}

.home-carousel .container,
.home-carousel .owl-carousel {
    position: relative;
    z-index: 2;
}

.home-carousel .owl-carousel {
    padding-top: 96px;
    padding-bottom: 64px;
}

.home-carousel .item > a {
    color: inherit;
    cursor: pointer;
    display: block;
    text-decoration: none;
}

.home-carousel .item > a:focus,
.home-carousel .item > a:hover {
    color: inherit;
    text-decoration: none;
}

.home-carousel .right {
    text-align: left;
}

.home-carousel h1,
.home-carousel h2,
.home-carousel h3,
.home-carousel p,
.home-carousel ul {
    text-transform: none;
    letter-spacing: 0;
    font-weight: 400;
}

.home-carousel h1 {
    font-size: clamp(30px, 3.6vw, 48px);
    letter-spacing: -0.02em;
    font-weight: 600;
    line-height: 1.12;
    max-width: 20ch;
    text-shadow: 0 12px 30px rgba(15, 23, 42, 0.35);
}

.home-carousel ul,
.home-carousel p {
    font-size: 18px;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.6;
}

.home-carousel .lead {
    font-size: 20px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.92);
    margin-bottom: 18px;
}

.home-carousel p {
    max-width: 42ch;
}

.home-carousel ul.list-style-none {
    margin-top: 18px;
    padding-left: 0;
    display: grid;
    gap: 10px;
}

.home-carousel ul.list-style-none li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    line-height: 1.55;
    margin-bottom: 0;
}

.home-carousel ul.list-style-none li i {
    font-size: 14px;
    margin-top: 3px;
    min-width: 16px;
}

.home-carousel img {
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(255, 255, 255, 0.16);
    background: rgba(15, 23, 42, 0.12);
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.home-carousel .owl-theme .owl-controls {
    margin-top: 18px;
}

.home-carousel .owl-theme .owl-controls .owl-page span {
    width: 11px;
    height: 11px;
    margin: 6px 7px;
    background: rgba(255, 255, 255, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.55);
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.25);
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.home-carousel .owl-theme .owl-controls .owl-page.active span,
.home-carousel .owl-theme .owl-controls.clickable .owl-page:hover span {
    background: #fff;
    border-color: #fff;
    transform: scale(1.05);
}

@media (hover: hover) {
    .home-carousel .item > a:hover img {
        transform: translateY(-4px);
        box-shadow: 0 28px 70px rgba(2, 6, 23, 0.45);
    }
}

@keyframes heroFade {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.home-carousel h1 {
    animation: heroFade 0.6s ease-out both;
}

.home-carousel p,
.home-carousel ul {
    animation: heroFade 0.7s ease-out both;
    animation-delay: 0.12s;
}

.home-carousel img {
    animation: heroFade 0.8s ease-out both;
    animation-delay: 0.2s;
}

@keyframes cardRise {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.bar .box-simple {
    animation: cardRise 0.45s ease-out both;
}

.bar .row > [class*="col-"]:nth-child(2) .box-simple {
    animation-delay: 0.08s;
}

.bar .row > [class*="col-"]:nth-child(3) .box-simple {
    animation-delay: 0.16s;
}

@media (min-width: 992px) {
    .home-carousel .item .row {
        display: flex;
        align-items: center;
    }

    .home-carousel .item .row > [class*="col-"] {
        float: none;
    }

    .home-carousel .right {
        padding-right: 24px;
    }
}

@media (max-width: 991px) {
    .home-carousel .owl-carousel {
        padding-top: 72px;
        padding-bottom: 52px;
    }

    .home-carousel h1 {
        font-size: 36px;
    }
}

@media (max-width: 767px) {
    .home-carousel .right {
        text-align: center;
    }

    .home-carousel h1 {
        font-size: 32px;
    }

    .home-carousel p {
        margin-left: auto;
        margin-right: auto;
    }

    .home-carousel ul.list-style-none {
        margin-left: auto;
        margin-right: auto;
        max-width: 320px;
        text-align: left;
    }

    .home-carousel img {
        margin-top: 24px;
    }
}

.service-section {
    margin-bottom: 60px;
}

/* Intro Panel / Hero Banner */
.intro-panel {
    background: var(--gradient-primary);
    padding: 60px 0;
    margin-bottom: 60px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.intro-content {
    max-width: 800px;
    margin: 0 auto;
}

.intro-panel .lead {
    color: rgba(255, 255, 255, 0.92);
    font-size: 24px;
    font-weight: 400;
    margin: 0;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    line-height: 1.4;
}

/* Process Steps */
.process-section {
    background: var(--color-surface);
    padding: 60px 0;
    margin: 60px -15px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-sm);
}

.process-step {
    text-align: center;
    padding: 30px 20px;
}

.step-number {
    width: 60px;
    height: 60px;
    background: var(--gradient-cta);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: bold;
    margin: 0 auto 20px;
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.2);
}

.process-step h4 {
    color: var(--color-text);
    margin-bottom: 15px;
    font-weight: 600;
}

.process-step p {
    color: var(--color-text-muted);
    line-height: 1.6;
}

/* Call to Action */
.cta-section {
    margin-top: 60px;
}

.cta-box {
    background: var(--gradient-primary);
    color: #fff;
    padding: 50px 40px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.cta-box h3 {
    color: white;
    margin-bottom: 20px;
    font-weight: 600;
}

.cta-box .lead {
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 30px;
}

.cta-box .btn-template-main {
    background: #fff;
    border-color: #fff;
    color: var(--color-primary);
    box-shadow: none;
}

.cta-box .btn-template-main:hover {
    background-color: rgba(255, 255, 255, 0.92);
    border-color: rgba(255, 255, 255, 0.92);
    color: var(--color-secondary);
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.2);
}

/* Form Styles */
.form-group {
    margin-bottom: 25px;
}

.form-group label {
    color: var(--color-text);
    font-weight: 600;
    margin-bottom: 8px;
    display: block;
}

.form-control {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    padding: 12px 15px;
    font-size: 16px;
    transition: border-color 0.3s ease;
    width: 100%;
}

.form-control:focus {
    border-color: var(--color-secondary);
    box-shadow: 0 0 0 0.2rem rgba(26, 156, 140, 0.2);
    outline: none;
}

/* Why Choose Us (Home / Contact Shared) */
.why-choose-us {
    background: var(--color-surface);
    padding: 50px 40px;
    border-radius: var(--radius-lg);
    margin-top: 50px;
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-sm);
}

.why-choose-us h2 {
    color: var(--color-text);
    text-align: center;
    margin-bottom: 40px;
    font-weight: 700;
}

.benefit-item {
    text-align: center;
    padding: 30px 20px;
}

.benefit-item i {
    font-size: 3rem;
    color: var(--color-secondary);
    margin-bottom: 20px;
}

.benefit-item h4 {
    color: var(--color-text);
    margin-bottom: 15px;
    font-weight: 600;
}

.benefit-item p {
    color: var(--color-text-muted);
    line-height: 1.6;
}

/* Shared Responsive Overrides for Components */
@media (max-width: 768px) {
    .process-section {
        margin: 40px -15px;
        padding: 40px 0;
    }

    .cta-box {
        padding: 40px 30px;
    }

    .intro-panel {
        padding: 40px 0;
        margin-bottom: 40px;
    }

    .intro-panel .lead {
        font-size: 20px;
        padding: 0 20px;
    }

    .heading {
        margin-bottom: 40px;
    }

    .why-choose-us {
        padding: 30px 20px;
        margin-top: 30px;
    }

    .benefit-item {
        margin-bottom: 30px;
    }
}
