/* ============================================
   PUFFLIO - APPLE-STYLE REFINEMENTS
   Premium, polished design system
   ============================================ */

/* ============================================
   SMOOTH SCROLLING & BASE
   ============================================ */
html {
    scroll-behavior: smooth;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ============================================
   SUBTLE ANIMATIONS
   ============================================ */

/* Gentle fade in on scroll */
@keyframes subtleFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

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

/* Smooth scale for buttons */
@keyframes gentleScale {
    from {
        transform: scale(1);
    }

    to {
        transform: scale(1.02);
    }
}

/* ============================================
   IMPROVED BUTTONS
   ============================================ */

button,
.btn {
    min-height: 44px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

button:hover,
.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(45, 75, 45, 0.15);
}

button:active,
.btn:active {
    transform: translateY(0);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Primary button refinement */
.bg-primary {
    background: linear-gradient(135deg, #2D4B2D 0%, #1A2418 100%);
}

.bg-primary:hover {
    background: linear-gradient(135deg, #1A2418 0%, #2D4B2D 100%);
}

/* ============================================
   IMAGE TREATMENTS
   ============================================ */

/* Softer corners and better shadows */
.rounded-sm {
    border-radius: 8px !important;
}

/* Subtle zoom on hover */
.hover-zoom {
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.hover-zoom:hover {
    transform: scale(1.05);
}

/* Better image containers */
[class*="aspect-"] {
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: box-shadow 0.3s ease;
}

[class*="aspect-"]:hover {
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

/* ============================================
   CARD REFINEMENTS
   ============================================ */

/* Better card styling */
.card-refined {
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 12px;
    padding: 2.5rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-refined:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
    border-color: rgba(45, 75, 45, 0.15);
}

/* ============================================
   TYPOGRAPHY REFINEMENTS
   ============================================ */

/* Better heading hierarchy */
h1,
h2,
h3 {
    font-weight: 700;
    letter-spacing: -0.02em;
}

/* Body text improvements */
p {
    font-weight: 400;
    line-height: 1.7;
    letter-spacing: 0.01em;
}

/* Hero text shadow for depth */
.hero-content h1 {
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

.hero-content span,
.hero-content p {
    text-shadow: 0 1px 10px rgba(0, 0, 0, 0.2);
}

/* ============================================
   SPACING REFINEMENTS
   ============================================ */

/* More generous section spacing */
section {
    padding-top: 6rem;
    padding-bottom: 6rem;
}

@media (min-width: 768px) {
    section {
        padding-top: 8rem;
        padding-bottom: 8rem;
    }
}

/* ============================================
   HEADER REFINEMENTS
   ============================================ */

header {
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    background-color: rgba(255, 255, 255, 0.92);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

header.scrolled {
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.06);
}

/* ============================================
   LINK REFINEMENTS
   ============================================ */

a {
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

a:hover {
    opacity: 0.8;
}

/* ============================================
   FORM REFINEMENTS
   ============================================ */

input[type="email"] {
    transition: all 0.3s ease;
    font-size: 16px;
    /* Prevents zoom on iOS */
    border-bottom: 1px solid rgba(0, 0, 0, 0.15) !important;
}

input[type="email"]:focus {
    border-bottom-color: #2D4B2D !important;
    box-shadow: none;
    outline: none;
}

/* ============================================
   SUBTLE SCROLL ANIMATIONS
   ============================================ */

.fade-in-on-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================
   GRADIENT OVERLAYS
   ============================================ */

.gradient-overlay {
    position: relative;
}

.gradient-overlay::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.02) 100%);
    pointer-events: none;
}

/* ============================================
   FOCUS STATES (Accessibility)
   ============================================ */

button:focus-visible,
a:focus-visible,
input:focus-visible {
    outline: 2px solid #2D4B2D;
    outline-offset: 2px;
}

/* ============================================
   PERFORMANCE OPTIMIZATIONS
   ============================================ */

/* GPU acceleration for transforms */
.will-transform {
    will-change: transform;
}

/* Smooth transitions */
* {
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============================================
   RESPONSIVE REFINEMENTS
   ============================================ */

@media (max-width: 768px) {
    section {
        padding-top: 4rem;
        padding-bottom: 4rem;
    }

    h1 {
        font-size: 2.5rem !important;
    }
}