@import url('https://fonts.googleapis.com/css2?family=Caveat:wght@400;700&family=Lora:ital,wght@0,400;0,700;1,400&family=Playfair+Display:ital,wght@0,400;0,700;1,400&display=swap');

:root {
    --bg-color: #FEFEFC;
    /* Light Cream Background for Black Logo */
    --page-color: #FFFFFF;
    /* White Pages */
    --text-color: #333333;
    /* Dark Grey/Black Text */
    --accent-color: #000000;
    /* Black Accent matching Logo */
    --highlight-color: #D4AF37;
    /* Gold Highlight */
    --shadow-color: rgba(0, 0, 0, 0.1);
    /* Lighter shadow for light theme */
    --transition: all 0.8s cubic-bezier(0.25, 0.8, 0.25, 1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Lora', serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    background-image: radial-gradient(#38404a 1px, transparent 1px);
    background-size: 20px 20px;
}

/* Minimalist Sketchbook / Art Book Container */
#notebook-container {
    position: relative;
    width: 90vw;
    max-width: 1000px;
    height: 85vh;
    max-height: 750px;
    perspective: 2500px;
}

#book {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    box-shadow: 0 50px 100px rgba(0, 0, 0, 0.5);
    /* Stronger shadow for pop */
}

/* Cover specific styling */
.cover-contact-info {
    margin-top: 20px;
    text-align: center;
    font-size: 0.95rem;
    color: #555;
    border-top: 1px solid #eee;
    padding-top: 15px;
}

.cover-contact-info p {
    margin-bottom: 5px;
}

.cover-cta {
    font-style: italic;
    margin-bottom: 15px;
    color: var(--highlight-color);
    font-weight: bold;
}

/* Pages */
.page {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding: 60px 80px;
    background-color: var(--page-color);
    border-radius: 4px;
    /* Minimal radius */
    transform-origin: left center;
    transition: var(--transition);
    border-left: 1px solid #eee;
    /* Slight binding hint */
    /* Remove heavy paper texture, keep it clean */
    backface-visibility: hidden;
    z-index: 1;
    display: flex;
    flex-direction: column;
    box-shadow: inset -10px 0 20px rgba(0, 0, 0, 0.02);
}

.page.flipped {
    transform: rotateY(-180deg);
    opacity: 0;
    /* Add opacity fade for smoother visual */
    pointer-events: none;
}

/* Typography */
h1,
h2,
h3 {
    font-family: 'Playfair Display', serif;
    /* More artistic/elegant */
    color: var(--accent-color);
    margin-bottom: 1.5rem;
    font-weight: 400;
    letter-spacing: 1px;
}

h1 {
    font-size: 3rem;
    text-align: center;
    margin-top: 2rem;
}

h2 {
    font-size: 2rem;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
    display: inline-block;
}

p,
li {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #555;
    margin-bottom: 1rem;
}

/* Media Styling */
img,
iframe {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    /* Soft artistic shadow */
    border-radius: 2px;
    transition: transform 0.4s ease;
    filter: grayscale(20%);
    /* Artistic touch */
}

img:hover,
iframe:hover {
    transform: scale(1.01);
    filter: grayscale(0%);
}

.page-content {
    overflow-y: auto;
    height: 100%;
    padding-right: 20px;
    /* Custom Scrollbar minimal */
    scrollbar-width: thin;
    scrollbar-color: #ddd transparent;
}

.page-content::-webkit-scrollbar {
    width: 6px;
}

.page-content::-webkit-scrollbar-thumb {
    background-color: #ddd;
    border-radius: 3px;
}

/* Navigation - Minimal Arrows */
.nav-btn {
    position: absolute;
    top: 50%;
    background: white;
    color: var(--accent-color);
    border: 1px solid #eee;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    z-index: 100;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    opacity: 0.8;
}

.nav-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    opacity: 1;
    color: var(--highlight-color);
}

.prev-btn {
    left: -80px;
}

.next-btn {
    right: -80px;
}

/* Social Icons Minimal */
.social-bar {
    margin-top: auto;
    padding-top: 20px;
    display: flex;
    justify-content: center;
    gap: 20px;
    border-top: 1px solid #f0f0f0;
}

.social-link {
    color: #999;
    font-size: 1.5rem;
    transition: color 0.3s, transform 0.3s;
}

.social-link:hover {
    color: var(--highlight-color);
    transform: translateY(-3px);
}

/* Contact Grid Minimal */
.contact-grid {
    display: grid;
    gap: 15px;
    color: #666;
    margin-top: 30px;
}

.contact-item {
    display: flex;
    align-items: center;
    font-size: 1rem;
}

.contact-item i {
    width: 30px;
    color: var(--highlight-color);
}

/* Animations */
@keyframes fadeInSlide {
    from {
        opacity: 0;
        transform: translateY(15px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.page-content>* {
    animation: fadeInSlide 0.6s ease-out forwards;
}

/* Responsive */
/* Responsive */
@media (max-width: 900px) {
    #notebook-container {
        width: 100vw;
        height: 100vh;
        max-width: none;
        padding-bottom: 70px; /* Space for nav buttons */
        position: relative;
    }

    #book {
        box-shadow: none; /* Reduce shadow on small screens for performance/look */
    }

    .page {
        padding: 40px 20px;
        border-radius: 0;
        box-shadow: none;
        border: none;
    }

    .nav-btn {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
        background: rgba(255, 255, 255, 0.9);
        border: 1px solid #ccc;
        box-shadow: 0 4px 10px rgba(0,0,0,0.15);
        opacity: 1; /* Always visible on touch interaction */
    }

    /* Move buttons to bottom center */
    .prev-btn {
        top: auto;
        bottom: 20px;
        left: 20px;
        transform: none;
    }

    .next-btn {
        top: auto;
        bottom: 20px;
        right: 20px;
        transform: none;
    }

    h1 {
        font-size: 2rem;
        margin-top: 1rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    p, li, .contact-item {
        font-size: 1rem;
    }
}

@media (max-width: 600px) {
    .page {
        padding: 60px 20px 80px 20px; /* Top padding to avoid notch/browser bar, bottom for nav */
    }

    h1 {
        font-size: 1.8rem;
    }

    .cover-title {
        font-size: 2rem;
        margin-top: 0;
    }
    
    .cover-contact-info p {
        font-size: 0.9rem;
    }

    img {
        max-height: 250px; /* Limit height of images on mobile so they don't take full screen */
        object-fit: contain;
    }

    /* Center navigation buttons at the bottom for easier thumb reach */
    .nav-btn {
        width: 60px;
        height: 60px;
        position: fixed; /* Fixed position ensures visibility */
        bottom: calc(25px + env(safe-area-inset-bottom)); /* Respect safe area for iPhone X+ */
        z-index: 1000;
        /* Ensure touch target is large enough (already 60px > 44px) */
    }

    .prev-btn {
        left: 20px;
    }

    .next-btn {
        right: 20px;
    }
}