/* ============================================
   Bambick Joseph M — Custom Styles
   Vibrant Modern | Terracotta + Sand
   ============================================ */

/* ---------- Base ---------- */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    position: relative;
}

::selection {
    background: #e05535;
    color: #fff;
}

/* ---------- Geometric Background Shapes ---------- */
.geo-shape {
    position: fixed;
    pointer-events: none;
    z-index: 0;
    opacity: 0.4;
}

.shape-circle-1 {
    top: 15%;
    left: -5%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(224, 85, 53, 0.08) 0%, transparent 70%);
    border-radius: 50%;
    animation: float-slow 20s ease-in-out infinite;
}

.shape-circle-2 {
    bottom: 20%;
    right: -5%;
    width: 250px;
    height: 250px;
    background: radial-gradient(circle, rgba(202, 138, 4, 0.08) 0%, transparent 70%);
    border-radius: 50%;
    animation: float-slow 25s ease-in-out infinite reverse;
}

.shape-triangle {
    top: 40%;
    right: 5%;
    width: 0;
    height: 0;
    border-left: 60px solid transparent;
    border-right: 60px solid transparent;
    border-bottom: 104px solid rgba(224, 85, 53, 0.04);
    animation: spin-slow 30s linear infinite;
}

.shape-square {
    top: 60%;
    left: 8%;
    width: 80px;
    height: 80px;
    border: 2px solid rgba(224, 85, 53, 0.06);
    transform: rotate(45deg);
    animation: float-slow 18s ease-in-out infinite;
}

.shape-line {
    top: 25%;
    right: 15%;
    width: 120px;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(224, 85, 53, 0.1), transparent);
    transform: rotate(-30deg);
    animation: float-slow 22s ease-in-out infinite reverse;
}

/* Hero geometric overlays */
.geo-overlay {
    position: absolute;
    pointer-events: none;
}

.shape-geo-1 {
    top: 10%;
    right: 5%;
    width: 200px;
    height: 200px;
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 30px;
    transform: rotate(15deg);
    animation: float-slow 15s ease-in-out infinite;
}

.shape-geo-2 {
    bottom: 20%;
    left: 10%;
    width: 120px;
    height: 120px;
    background: rgba(250, 204, 21, 0.1);
    border-radius: 20px;
    transform: rotate(30deg);
    animation: float-slow 12s ease-in-out infinite reverse;
}

.shape-geo-3 {
    top: 50%;
    right: 20%;
    width: 60px;
    height: 60px;
    border: 2px solid rgba(255, 255, 255, 0.08);
    border-radius: 50%;
    animation: float-slow 10s ease-in-out infinite;
}

/* ---------- Animations ---------- */
@keyframes float-slow {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25% { transform: translateY(-20px) rotate(2deg); }
    50% { transform: translateY(-10px) rotate(-1deg); }
    75% { transform: translateY(-25px) rotate(1deg); }
}

@keyframes spin-slow {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

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

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes drawLine {
    from { width: 0; }
    to { width: 100%; }
}

/* ---------- Reveal Animations ---------- */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* ---------- Hero Animations ---------- */
.hero-tag {
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.2s both;
}

.hero-headline {
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.4s both;
}

.hero-sub {
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.6s both;
}

.hero-cta {
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.8s both;
}

/* ---------- Scroll Line ---------- */
.scroll-line {
    animation: fadeIn 1s ease 1.5s both;
}

/* ---------- Navbar ---------- */
#navbar {
    background: transparent;
    transition: background 0.4s ease, box-shadow 0.4s ease, padding 0.4s ease;
}

#navbar.scrolled {
    background: rgba(250, 248, 245, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06);
    padding-top: 0;
    padding-bottom: 0;
}

#navbar.scrolled .nav-link {
    color: rgba(26, 26, 26, 0.7);
}

#navbar.scrolled .cta-primary {
    background: #e05535;
}

/* ---------- Section Tags ---------- */
.section-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

/* ---------- Service Cards ---------- */
.service-card {
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1),
                box-shadow 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.service-card:hover {
    transform: translateY(-8px);
}

/* ---------- Feature Cards ---------- */
.feature-card {
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1),
                background 0.3s ease;
}

/* ---------- Contact Items ---------- */
.contact-item {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.contact-item:hover {
    transform: translateX(8px);
}

/* ---------- CTA Buttons ---------- */
.cta-primary {
    position: relative;
    overflow: hidden;
}

.cta-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
    transition: left 0.5s ease;
}

.cta-primary:hover::before {
    left: 100%;
}

/* ---------- Mobile Menu ---------- */
#mobileMenu.open {
    opacity: 1;
    pointer-events: all;
}

#mobileMenu.closed {
    opacity: 0;
    pointer-events: none;
}

.mobile-link {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease;
}

#mobileMenu.open .mobile-link {
    opacity: 1;
    transform: translateY(0);
}

#mobileMenu.open .mobile-link:nth-child(1) { transition-delay: 0.1s; }
#mobileMenu.open .mobile-link:nth-child(2) { transition-delay: 0.15s; }
#mobileMenu.open .mobile-link:nth-child(3) { transition-delay: 0.2s; }
#mobileMenu.open .mobile-link:nth-child(4) { transition-delay: 0.25s; }

/* ---------- Menu Icon Animation ---------- */
#menuBtn[aria-expanded="true"] .menu-line:nth-child(1) {
    top: 8px;
    transform: rotate(45deg);
}

#menuBtn[aria-expanded="true"] .menu-line:nth-child(2) {
    opacity: 0;
}

#menuBtn[aria-expanded="true"] .menu-line:nth-child(3) {
    top: 8px;
    transform: rotate(-45deg);
}

/* ---------- Form Styles ---------- */
select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
}

select:focus,
input:focus,
textarea:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(224, 85, 53, 0.15);
}

/* ---------- Smooth scroll offset for fixed nav ---------- */
section[id] {
    scroll-margin-top: 80px;
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
    .geo-shape {
        display: none;
    }

    .shape-circle-1,
    .shape-circle-2 {
        display: none;
    }
}

@media (min-width: 768px) and (max-width: 1024px) {
    .shape-triangle,
    .shape-square,
    .shape-line {
        display: none;
    }
}

/* ---------- Print ---------- */
@media print {
    .geo-shape,
    .geo-overlay,
    #navbar,
    .scroll-line {
        display: none !important;
    }
}
