/* ===== CSS Variables ===== */
:root {
    --color-primary: #1a1a1a;
    --color-secondary: #666;
    --color-accent: #c9a87c;
    --color-background: #fff;
    --color-background-alt: #f8f8f8;
    --color-border: #e5e5e5;
    --font-heading: 'Cormorant Garamond', Georgia, serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.08);
    --shadow-medium: 0 8px 30px rgba(0, 0, 0, 0.12);
}

/* ===== Reset & Base ===== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    font-weight: 400;
    line-height: 1.7;
    color: var(--color-primary);
    background-color: var(--color-background);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition-smooth);
}

/* ===== Typography ===== */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 400;
    line-height: 1.2;
}

.section-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    margin-bottom: 3rem;
    text-align: center;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 2px;
    background: var(--color-accent);
    margin: 1rem auto 0;
}

/* ===== Layout ===== */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* ===== Navigation ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid transparent;
    transition: var(--transition-smooth);
}

.navbar.scrolled {
    border-bottom-color: var(--color-border);
    box-shadow: var(--shadow-soft);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

.nav-logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 600;
    letter-spacing: -0.02em;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2.5rem;
}

.nav-link {
    font-size: 0.875rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--color-primary);
    transition: var(--transition-smooth);
}

.nav-link:hover::after {
    width: 100%;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.nav-toggle span {
    display: block;
    width: 25px;
    height: 2px;
    background: var(--color-primary);
    transition: var(--transition-smooth);
}

/* ===== Hero Section ===== */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 10rem 2rem 4rem;
    background: url('/images/jayrozanski-hero.png') center 30% / cover no-repeat;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
}

.hero-title,
.hero-tagline,
.hero-subtitle {
    color: #fff !important;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8), 0 4px 20px rgba(0, 0, 0, 0.6);
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 900px;
}

.hero-title {
    font-size: clamp(3rem, 8vw, 6rem);
    font-weight: 400;
    letter-spacing: -0.03em;
    margin-bottom: 1rem;
    animation: fadeInUp 1s ease-out;
}

.hero-tagline {
    font-family: var(--font-heading);
    font-size: clamp(1.25rem, 3vw, 1.75rem);
    font-style: italic;
    color: var(--color-secondary);
    margin-bottom: 0.5rem;
    animation: fadeInUp 1s ease-out 0.2s both;
}

.hero-subtitle {
    font-size: 0.875rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--color-accent);
    margin-bottom: 2.5rem;
    animation: fadeInUp 1s ease-out 0.4s both;
}

.hero-cta {
    display: inline-block;
    padding: 1rem 2.5rem;
    border: 2px solid #fff;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    transition: var(--transition-smooth);
    animation: fadeInUp 1s ease-out 0.6s both;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.hero-cta:hover {
    background: #fff;
    color: var(--color-primary);
}

.hero-scroll {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    animation: bounce 2s infinite;
}

.hero-scroll span {
    display: block;
    width: 24px;
    height: 40px;
    border: 2px solid var(--color-primary);
    border-radius: 12px;
    position: relative;
}

.hero-scroll span::before {
    content: '';
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 8px;
    background: var(--color-primary);
    border-radius: 2px;
    animation: scrollWheel 2s infinite;
}

/* ===== About Section ===== */
.about {
    padding: 8rem 0;
    background: var(--color-background);
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
}

.about-text {
    font-size: 1.125rem;
    line-height: 1.9;
    color: var(--color-secondary);
}

.about-text p {
    margin-bottom: 1.5rem;
}

.about-text strong {
    color: var(--color-primary);
    font-weight: 600;
}

.about-text a {
    color: var(--color-primary);
    border-bottom: 1px solid var(--color-accent);
    transition: var(--transition-smooth);
}

.about-text a:hover {
    border-bottom-color: var(--color-primary);
}

.about-closing {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--color-border);
    font-style: italic;
}

/* ===== Portfolio Section - Avenue Template Style ===== */
.portfolio {
    position: relative;
    background: var(--color-primary);
}

/* Navigation Dots */
.portfolio-nav {
    position: fixed;
    right: 2rem;
    top: 50%;
    transform: translateY(-50%);
    z-index: 100;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.portfolio-nav-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    border: 2px solid transparent;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.portfolio-nav-dot:hover,
.portfolio-nav-dot.active {
    background: #fff;
    border-color: #fff;
    transform: scale(1.2);
}

/* Index Sections - Full viewport height sections */
.index-section {
    position: relative;
    min-height: 100vh;
    width: 100%;
    display: flex;
    align-items: center;
    overflow: hidden;
}

/* Background Image with Parallax */
.index-section-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    background-color: #333;
    will-change: transform;
    z-index: 0;
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
}

/* Dark Overlay for text readability */
.index-section-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    background: linear-gradient(
        to right,
        rgba(0, 0, 0, 0.7) 0%,
        rgba(0, 0, 0, 0.4) 50%,
        rgba(0, 0, 0, 0.1) 100%
    );
}

.index-section-right .index-section-overlay {
    background: linear-gradient(
        to left,
        rgba(0, 0, 0, 0.7) 0%,
        rgba(0, 0, 0, 0.4) 50%,
        rgba(0, 0, 0, 0.1) 100%
    );
}

/* Content Positioning */
.index-section-content {
    position: relative;
    z-index: 2;
    max-width: 600px;
    padding: 4rem;
    margin-left: 5%;
    color: #fff;
}

.index-section-right .index-section-content {
    margin-left: auto;
    margin-right: 5%;
    text-align: right;
}

/* Typography */
.index-section-role {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--color-accent);
    margin-bottom: 1rem;
}

.index-section-title {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    font-weight: 400;
    margin-bottom: 0.5rem;
    line-height: 1.1;
    color: #fff;
}

.index-section-client {
    font-size: 0.875rem;
    font-weight: 500;
    letter-spacing: 0.05em;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 1.5rem;
}

.index-section-quote {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-style: italic;
    line-height: 1.6;
    border-left: 3px solid var(--color-accent);
    padding-left: 1.5rem;
    margin: 1.5rem 0;
    color: rgba(255, 255, 255, 0.9);
}

.index-section-right .index-section-quote {
    border-left: none;
    border-right: 3px solid var(--color-accent);
    padding-left: 0;
    padding-right: 1.5rem;
}

.index-section-quote cite {
    display: block;
    margin-top: 0.75rem;
    font-size: 0.875rem;
    font-style: normal;
    font-family: var(--font-body);
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.index-section-excerpt {
    font-size: 1rem;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 2rem;
}

/* CTA Button */
.index-section-cta {
    display: inline-block;
    padding: 1rem 2.5rem;
    background: transparent;
    border: 1px solid #fff;
    color: #fff;
    font-family: var(--font-body);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.index-section-cta:hover {
    background: #fff;
    color: var(--color-primary);
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    cursor: pointer;
    animation: bounce 2s infinite;
}

.index-section:last-child .scroll-indicator {
    display: none;
}

.scroll-arrow {
    display: block;
    width: 30px;
    height: 50px;
    border: 2px solid rgba(255, 255, 255, 0.5);
    border-radius: 15px;
    position: relative;
    transition: var(--transition-smooth);
}

.scroll-arrow::before {
    content: '';
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 6px;
    height: 10px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 3px;
    animation: scrollWheel 2s infinite;
}

.scroll-indicator:hover .scroll-arrow {
    border-color: #fff;
}

/* Legacy classes for compatibility */
.portfolio-grid,
.portfolio-item,
.portfolio-image,
.portfolio-content,
.portfolio-role,
.portfolio-title,
.portfolio-client,
.portfolio-excerpt,
.portfolio-read-more {
    display: none;
}

/* ===== Modal ===== */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    z-index: 2000;
    padding: 2rem;
    overflow-y: auto;
    backdrop-filter: blur(5px);
}

.modal.active {
    display: flex;
    justify-content: center;
    align-items: flex-start;
}

.modal-content {
    background: #fff;
    max-width: 800px;
    width: 100%;
    margin: 2rem auto;
    border-radius: 4px;
    position: relative;
    animation: modalIn 0.3s ease-out;
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 40px;
    height: 40px;
    background: none;
    border: none;
    font-size: 2rem;
    line-height: 1;
    cursor: pointer;
    color: var(--color-primary);
    z-index: 10;
    transition: var(--transition-smooth);
}

.modal-close:hover {
    color: var(--color-accent);
    transform: rotate(90deg);
}

.modal-body {
    padding: 3rem;
}

.modal-body h3 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.modal-body .modal-role {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--color-accent);
    margin-bottom: 1rem;
}

.modal-body .modal-client {
    font-size: 0.875rem;
    color: var(--color-secondary);
    margin-bottom: 2rem;
}

.modal-body p {
    color: var(--color-secondary);
    line-height: 1.9;
    margin-bottom: 1.25rem;
}

.modal-body blockquote {
    border-left: 3px solid var(--color-accent);
    padding-left: 1.5rem;
    margin: 2rem 0;
    font-style: italic;
    color: var(--color-primary);
}

.modal-body cite {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.875rem;
    font-style: normal;
    color: var(--color-secondary);
}

.modal-body a {
    color: var(--color-primary);
    border-bottom: 1px solid var(--color-accent);
}

.modal-body a:hover {
    border-bottom-color: var(--color-primary);
}

/* ===== Contact Section ===== */
.contact {
    padding: 8rem 0;
    background: var(--color-background);
}

.contact-content {
    max-width: 600px;
    margin: 0 auto;
}

.contact-methods {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    background: var(--color-background-alt);
    border-radius: 4px;
    transition: var(--transition-smooth);
}

.contact-item:hover {
    background: var(--color-primary);
    color: #fff;
    transform: translateX(10px);
}

.contact-icon {
    font-size: 1.5rem;
    width: 40px;
    text-align: center;
}

.contact-label {
    font-size: 1rem;
    font-weight: 500;
}

/* ===== Footer ===== */
.footer {
    padding: 3rem 0;
    background: var(--color-primary);
    color: #888;
    text-align: center;
}

.footer p {
    font-size: 0.875rem;
    margin-bottom: 1rem;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
}

.footer-links a {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: var(--transition-smooth);
}

.footer-links a:hover {
    color: #fff;
}

/* ===== Animations ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    40% {
        transform: translateX(-50%) translateY(-10px);
    }
    60% {
        transform: translateX(-50%) translateY(-5px);
    }
}

@keyframes scrollWheel {
    0% {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
    100% {
        opacity: 0;
        transform: translateX(-50%) translateY(12px);
    }
}

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

/* ===== Responsive Design ===== */
@media (max-width: 992px) {
    .index-section-bg {
        background-attachment: scroll;
    }
    
    .index-section-content {
        max-width: 500px;
        padding: 3rem;
        margin-left: 3%;
    }
    
    .index-section-right .index-section-content {
        margin-right: 3%;
    }
    
    .index-section-title {
        font-size: clamp(2rem, 6vw, 3rem);
    }
}

@media (max-width: 768px) {
    .portfolio-nav {
        right: 1rem;
        gap: 0.75rem;
    }
    
    .portfolio-nav-dot {
        width: 8px;
        height: 8px;
    }
    
    .index-section {
        min-height: 100vh;
        align-items: flex-end;
    }
    
    .index-section-content {
        max-width: 100%;
        padding: 2rem;
        margin: 0;
        text-align: left;
        background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.6) 60%, transparent 100%);
    }
    
    .index-section-right .index-section-content {
        margin: 0;
        text-align: left;
    }
    
    .index-section-overlay {
        background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.3) 50%, rgba(0, 0, 0, 0.1) 100%);
    }
    
    .index-section-right .index-section-overlay {
        background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.3) 50%, rgba(0, 0, 0, 0.1) 100%);
    }
    
    .index-section-quote {
        border-left: 3px solid var(--color-accent);
        padding-left: 1rem;
        padding-right: 0;
        border-right: none;
    }
    
    .index-section-right .index-section-quote {
        border-left: 3px solid var(--color-accent);
        padding-left: 1rem;
        padding-right: 0;
        border-right: none;
    }
    
    .index-section-excerpt {
        font-size: 0.9375rem;
    }
    
    .scroll-indicator {
        bottom: 1.5rem;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: rgba(255, 255, 255, 0.98);
        flex-direction: column;
        gap: 0;
        padding: 1rem 0;
        border-bottom: 1px solid var(--color-border);
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: var(--transition-smooth);
    }
    
    .nav-menu.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    
    .nav-menu li {
        text-align: center;
    }
    
    .nav-link {
        display: block;
        padding: 1rem;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .nav-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }
    
    .nav-toggle.active span:nth-child(2) {
        opacity: 0;
    }
    
    .nav-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -6px);
    }
    
    .hero {
        padding-top: 5rem;
    }
    
    .about,
    .portfolio,
    .contact {
        padding: 5rem 0;
    }
    
    .modal-content {
        margin: 0;
        border-radius: 0;
        min-height: 100vh;
    }
    
    .modal-body {
        padding: 2rem;
    }
}

@media (max-width: 480px) {
    .nav-container {
        padding: 0 1rem;
    }
    
    .hero {
        padding: 5rem 1rem 3rem;
    }
    
    .container {
        padding: 0 1rem;
    }
    
    .portfolio-content {
        padding: 1.5rem;
    }
    
    .contact-item {
        padding: 1rem;
    }
}

/* ===== Print Styles ===== */
@media print {
    .navbar,
    .hero-scroll,
    .portfolio-read-more,
    .modal,
    .footer-links {
        display: none !important;
    }
    
    .hero {
        min-height: auto;
        padding: 2rem 0;
    }
    
    .portfolio-item {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #ddd;
    }
}
