/* ============================================
   BUFFALO REAL ESTATE PARTNERS — STYLESHEET
   ============================================ */

/* ---------- Reset & Base ---------- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    --navy: #0c1b2e;
    --navy-light: #162d4a;
    --gold: #c8a45e;
    --gold-light: #e2c88a;
    --white: #ffffff;
    --off-white: #f7f5f0;
    --gray-100: #f1f1f1;
    --gray-200: #e0e0e0;
    --gray-400: #999;
    --gray-600: #666;
    --gray-800: #333;
    --font-heading: 'Playfair Display', Georgia, serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

html { scroll-behavior: smooth; font-size: 16px; }

body {
    font-family: var(--font-body);
    color: var(--gray-800);
    line-height: 1.6;
    background: var(--white);
    overflow-x: hidden;
}

a { text-decoration: none; color: inherit; transition: color var(--transition); }
img { max-width: 100%; height: auto; display: block; }

.container {
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* ---------- Typography ---------- */
.section-tag {
    font-family: var(--font-body);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 0.75rem;
}
.section-tag--light { color: var(--gold-light); }

.section-title {
    font-family: var(--font-heading);
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 700;
    line-height: 1.2;
    color: var(--navy);
    margin-bottom: 1rem;
}
.section-title--light { color: var(--white); }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.85rem 2rem;
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    border-radius: 4px;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all var(--transition);
    white-space: nowrap;
}
.btn-primary {
    background: var(--gold);
    color: var(--navy);
    border-color: var(--gold);
}
.btn-primary:hover {
    background: var(--gold-light);
    border-color: var(--gold-light);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(200,164,94,0.3);
}
.btn-outline {
    background: transparent;
    color: var(--white);
    border-color: rgba(255,255,255,0.4);
}
.btn-outline:hover {
    border-color: var(--white);
    background: rgba(255,255,255,0.1);
}
.btn-lg { padding: 1rem 2.5rem; font-size: 1rem; }
.btn-full { width: 100%; }

/* ---------- Header ---------- */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 1rem 0;
    transition: all var(--transition);
}
.header.scrolled {
    background: rgba(12, 27, 46, 0.97);
    backdrop-filter: blur(12px);
    padding: 0.6rem 0;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}
.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.logo img {
    height: 50px;
    width: auto;
    transition: height var(--transition);
}
.header.scrolled .logo img { height: 40px; }

.nav {
    display: flex;
    align-items: center;
    gap: 2rem;
}
.nav-link {
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 0.5px;
    color: rgba(255,255,255,0.85);
    position: relative;
    padding: 0.25rem 0;
}
.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gold);
    transition: width var(--transition);
}
.nav-link:hover { color: var(--white); }
.nav-link:hover::after { width: 100%; }

.nav-link--cta {
    background: var(--gold);
    color: var(--navy) !important;
    padding: 0.6rem 1.5rem;
    border-radius: 4px;
    font-weight: 600;
}
.nav-link--cta::after { display: none; }
.nav-link--cta:hover {
    background: var(--gold-light);
    transform: translateY(-1px);
}

/* Burger */
.burger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    z-index: 1001;
}
.burger span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--white);
    transition: all var(--transition);
}
.burger.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.burger.active span:nth-child(2) { opacity: 0; }
.burger.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ---------- Hero ---------- */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    background:
        linear-gradient(135deg, rgba(12,27,46,0.92) 0%, rgba(22,45,74,0.85) 100%),
        url('https://images.unsplash.com/photo-1486325212027-8081e485255e?w=1920&q=80') center/cover no-repeat;
    overflow: hidden;
}
.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 60%, rgba(12,27,46,0.6) 100%);
}
.hero-content {
    position: relative;
    z-index: 2;
    padding: 8rem 2rem 4rem;
}
.hero-tag {
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 1.5rem;
    opacity: 0;
    animation: fadeUp 0.8s 0.3s forwards;
}
.hero-title {
    font-family: var(--font-heading);
    font-size: clamp(2.2rem, 5.5vw, 4rem);
    font-weight: 700;
    line-height: 1.15;
    color: var(--white);
    margin-bottom: 1.5rem;
    opacity: 0;
    animation: fadeUp 0.8s 0.5s forwards;
}
.hero-title .accent { color: var(--gold); }
.hero-desc {
    font-size: 1.05rem;
    color: rgba(255,255,255,0.75);
    max-width: 620px;
    line-height: 1.7;
    margin-bottom: 2.5rem;
    opacity: 0;
    animation: fadeUp 0.8s 0.7s forwards;
}
.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    opacity: 0;
    animation: fadeUp 0.8s 0.9s forwards;
}
.hero-scroll {
    position: absolute;
    bottom: 2rem;
    right: 3rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255,255,255,0.5);
    font-size: 0.7rem;
    letter-spacing: 2px;
    text-transform: uppercase;
}
.scroll-line {
    width: 1px;
    height: 50px;
    background: linear-gradient(180deg, var(--gold), transparent);
    animation: scrollPulse 2s infinite;
}

@keyframes fadeUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes scrollPulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}

/* ---------- Stats ---------- */
.stats {
    background: var(--navy);
    padding: 3rem 0;
}
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    text-align: center;
}
.stat-item {
    padding: 1rem;
}
.stat-number {
    font-family: var(--font-heading);
    font-size: 2.8rem;
    font-weight: 700;
    color: var(--gold);
    display: inline;
}
.stat-plus {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    color: var(--gold);
    font-weight: 600;
}
.stat-label {
    display: block;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.6);
    margin-top: 0.25rem;
    letter-spacing: 0.5px;
}

/* ---------- About ---------- */
.about {
    padding: 6rem 0;
    background: var(--white);
}
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}
.about-image { position: relative; }
.about-img-wrapper {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0,0,0,0.12);
}
.about-img-wrapper img {
    width: 100%;
    height: 450px;
    object-fit: cover;
    transition: transform 0.6s ease;
}
.about-img-wrapper:hover img { transform: scale(1.03); }

.about-accent-box {
    position: absolute;
    bottom: -30px;
    right: -30px;
    background: var(--gold);
    color: var(--navy);
    padding: 1.5rem 2rem;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(200,164,94,0.3);
}
.accent-number {
    display: block;
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1;
}
.accent-text {
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    line-height: 1.4;
}

.about-text {
    color: var(--gray-600);
    margin-bottom: 1rem;
    line-height: 1.7;
}
.about-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    margin-top: 1.5rem;
}
.about-feature {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--navy);
}
.about-feature svg {
    width: 20px;
    height: 20px;
    color: var(--gold);
    flex-shrink: 0;
}

/* ---------- Services ---------- */
.services {
    padding: 6rem 0;
    background: var(--off-white);
}
.services-header {
    text-align: center;
    max-width: 650px;
    margin: 0 auto 3rem;
}
.services-desc {
    color: var(--gray-600);
    line-height: 1.7;
}
.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}
.service-card {
    background: var(--white);
    padding: 2.5rem 2rem;
    border-radius: 8px;
    border: 1px solid var(--gray-200);
    transition: all var(--transition);
    position: relative;
    overflow: hidden;
}
.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--gold);
    transform: scaleX(0);
    transition: transform var(--transition);
}
.service-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 40px rgba(0,0,0,0.08);
    border-color: transparent;
}
.service-card:hover::before { transform: scaleX(1); }

.service-icon {
    width: 48px;
    height: 48px;
    color: var(--gold);
    margin-bottom: 1.5rem;
}
.service-icon svg { width: 100%; height: 100%; }

.service-title {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--navy);
    margin-bottom: 0.75rem;
}
.service-text {
    font-size: 0.9rem;
    color: var(--gray-600);
    line-height: 1.7;
}

/* ---------- Portfolio / Why Us ---------- */
.portfolio {
    padding: 6rem 0;
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-light) 100%);
}
.portfolio-header {
    text-align: center;
    margin-bottom: 3rem;
}
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}
.portfolio-card {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.08);
    padding: 2.5rem;
    border-radius: 8px;
    transition: all var(--transition);
}
.portfolio-card:hover {
    background: rgba(255,255,255,0.08);
    border-color: var(--gold);
    transform: translateY(-4px);
}
.portfolio-number {
    font-family: var(--font-heading);
    font-size: 3rem;
    font-weight: 700;
    color: var(--gold);
    opacity: 0.3;
    line-height: 1;
    margin-bottom: 0.75rem;
}
.portfolio-card h3 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    color: var(--white);
    margin-bottom: 0.75rem;
}
.portfolio-card p {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.6);
    line-height: 1.7;
}

/* ---------- Testimonials ---------- */
.testimonials {
    padding: 6rem 0;
    background: var(--white);
}
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 2rem;
}
.testimonial-card {
    background: var(--off-white);
    padding: 2.5rem 2rem;
    border-radius: 8px;
    border: 1px solid var(--gray-200);
    transition: all var(--transition);
}
.testimonial-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.06);
}
.testimonial-stars {
    color: var(--gold);
    font-size: 1rem;
    margin-bottom: 1rem;
    letter-spacing: 2px;
}
.testimonial-text {
    font-size: 0.92rem;
    color: var(--gray-600);
    line-height: 1.7;
    font-style: italic;
    margin-bottom: 1.5rem;
}
.testimonial-author {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
.author-avatar {
    width: 44px;
    height: 44px;
    background: var(--navy);
    color: var(--gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 700;
    flex-shrink: 0;
}
.testimonial-author strong {
    display: block;
    font-size: 0.9rem;
    color: var(--navy);
}
.testimonial-author span {
    font-size: 0.8rem;
    color: var(--gray-400);
}

/* ---------- CTA ---------- */
.cta {
    padding: 5rem 0;
    background:
        linear-gradient(135deg, rgba(12,27,46,0.93) 0%, rgba(22,45,74,0.88) 100%),
        url('https://images.unsplash.com/photo-1497366216548-37526070297c?w=1920&q=80') center/cover no-repeat;
}
.cta-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}
.cta-content h2 {
    font-family: var(--font-heading);
    font-size: clamp(1.6rem, 3.5vw, 2.4rem);
    color: var(--white);
    margin-bottom: 1rem;
    line-height: 1.2;
}
.cta-content p {
    color: rgba(255,255,255,0.7);
    margin-bottom: 2rem;
    line-height: 1.7;
}

/* ---------- Contact ---------- */
.contact {
    padding: 6rem 0;
    background: var(--off-white);
}
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
}
.contact-desc {
    color: var(--gray-600);
    line-height: 1.7;
    margin-bottom: 2rem;
}
.contact-details { display: flex; flex-direction: column; gap: 1.5rem; }
.contact-item {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}
.contact-icon {
    width: 44px;
    height: 44px;
    background: var(--navy);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.contact-icon svg { width: 20px; height: 20px; color: var(--gold); }
.contact-item strong {
    display: block;
    font-size: 0.9rem;
    color: var(--navy);
    margin-bottom: 0.2rem;
}
.contact-item p {
    font-size: 0.9rem;
    color: var(--gray-600);
    line-height: 1.5;
}
.contact-item a { color: var(--gold); }
.contact-item a:hover { color: var(--navy); }

/* Contact Form */
.contact-form-wrapper {
    background: var(--white);
    border-radius: 8px;
    padding: 2.5rem;
    box-shadow: 0 10px 40px rgba(0,0,0,0.06);
}
.contact-form h3 {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    color: var(--navy);
    margin-bottom: 1.5rem;
}
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}
.form-group {
    margin-bottom: 1rem;
}
.form-group label {
    display: block;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--navy);
    margin-bottom: 0.4rem;
}
.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    font-family: var(--font-body);
    font-size: 0.9rem;
    border: 1px solid var(--gray-200);
    border-radius: 4px;
    background: var(--gray-100);
    transition: border-color var(--transition);
    outline: none;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--gold);
    background: var(--white);
}
.form-group textarea { resize: vertical; }

/* ---------- Footer ---------- */
.footer {
    background: var(--navy);
    padding: 4rem 0 0;
    color: rgba(255,255,255,0.6);
}
.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    padding-bottom: 3rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}
.footer-logo {
    height: 50px;
    margin-bottom: 1rem;
}
.footer-brand p {
    font-size: 0.85rem;
    line-height: 1.7;
    max-width: 280px;
}
.footer-links h4 {
    font-family: var(--font-heading);
    font-size: 1rem;
    color: var(--white);
    margin-bottom: 1rem;
}
.footer-links a,
.footer-links p {
    display: block;
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
    transition: color var(--transition);
}
.footer-links a:hover { color: var(--gold); }
.footer-bottom {
    padding: 1.5rem 0;
    text-align: center;
    font-size: 0.8rem;
}

/* ---------- Scroll Animations ---------- */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
    .services-grid { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
    .about-grid { gap: 3rem; }
}

@media (max-width: 768px) {
    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: var(--navy);
        flex-direction: column;
        justify-content: center;
        gap: 1.5rem;
        transition: right var(--transition);
        box-shadow: -10px 0 30px rgba(0,0,0,0.3);
    }
    .nav.open { right: 0; }
    .nav-link { font-size: 1.1rem; }
    .burger { display: flex; }

    .hero { min-height: 90vh; }
    .hero-title { font-size: clamp(1.8rem, 6vw, 2.8rem); }

    .stats-grid { grid-template-columns: repeat(2, 1fr); }

    .about-grid,
    .contact-grid { grid-template-columns: 1fr; }

    .about-accent-box { right: 10px; bottom: -20px; }

    .services-grid { grid-template-columns: 1fr; }
    .portfolio-grid { grid-template-columns: 1fr; }
    .testimonials-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
    .container { padding: 0 1.25rem; }
    .hero-actions { flex-direction: column; }
    .hero-actions .btn { width: 100%; text-align: center; }
    .form-row { grid-template-columns: 1fr; }
    .about-features { grid-template-columns: 1fr; }
    .hero-scroll { display: none; }
}
