/*
===================================================
Created by ForVera Media LLC. All rights reserved.
Developed by Christian Connett
Generated on 2025-03-22
===================================================
General > Layout > Navigation > Hero > Books > Testimonials > Contact > Footer > Utilities > Media Queries
===================================================
*/

/* Reset margin/padding and prevent overflow */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Loader Container */
#loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: #F8F4E3;  /* Match site background */
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
}

/* Spinning Animation */
@keyframes spinLoader {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Spinner Style */
.spinner-logo {
  width: 100px;
  height: 100px;
  animation: spinLoader 2s linear infinite;
  opacity: 0.9;
}


/* ========== General Styles ========== */
html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: 'Inter', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #F8F4E3;  /* Updated Background */
    color: #2B2D42;  /* Updated Primary Text */
    -webkit-touch-callout: none;
    -webkit-tap-highlight-color: rgba(0,0,0,0);
    background-color: #F8F4E3;  /* Existing background color */
    background-image: url('https://www.transparenttextures.com/patterns/paper-fibers.png');
    background-repeat: repeat;
    background-size: auto;  /* Native size for texture */
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: rgba(0,0,0,0);
}


/* ========== Navigation Styles ========== */
#main-nav {
    width: 100%;
    position: sticky;
    top: 0;
    z-index: 1000;
    font-weight:bold;
    background-color: #F4A261;  /* Header Color */
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid #E2E2E2;
    height: 100px;
    transition: height 0.3s ease, box-shadow 0.3s ease;
}

#main-nav.shrink {
    height: 70px;
}

.logo-img {
    max-height: 100px;
    transition: max-height 0.3s ease;
}

#main-nav.shrink .logo-img {
    max-height: 70px;
}

/* Add this to ensure nav-container doesn’t shrink */
.nav-container {
    display: flex;
    justify-content: space-between;  /* Ensures spacing between logo and links */
    align-items: center;
    padding: 10px 20px;
    flex-wrap: wrap;
    position: relative;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.nav-links {
    list-style: none;  /* This removes bullet points */
    margin: 0;
    padding: 0;
    display: flex;
    gap: 20px;
    align-items: center;
    text-transform: uppercase;
    margin-left: auto;  /* Align nav links to right */
}


.nav-links li a {
    text-decoration: none;
    color: #1E3D59;  /*  Nav Link Color */
    font-size: 1rem;
    padding: 8px 12px;
    transition: color 0.3s, background-color 0.3s;
    border-radius: 4px;
}

.nav-links li a:hover {
    color: #ffffff;
    background-color: #EF8354;  /* Updated Accent */
}


/* Hamburger Menu */
.menu-toggle {
    width: 30px;
    height: 24px;
    position: relative;
    cursor: pointer;
    display: none;
    z-index: 1001;
}


.menu-toggle .bar {
    display: block;
    position: absolute;
    height: 3px;
    width: 100%;
    background-color: #1E3D59;  /* Updated Hamburger Color */
    border-radius: 2px;
    opacity: 1;
    left: 0;
    transition: all 0.3s ease-in-out;
}

.menu-toggle .bar:nth-child(1) { top: 0; }
.menu-toggle .bar:nth-child(2) { top: 10px; }
.menu-toggle .bar:nth-child(3) { top: 20px; }

.menu-toggle.active .bar:nth-child(1) {
    transform: rotate(45deg);
    top: 10px;
}
.menu-toggle.active .bar:nth-child(2) {
    opacity: 0;
}
.menu-toggle.active .bar:nth-child(3) {
    transform: rotate(-45deg);
    top: 10px;
}


/* ======== LOGO ========*/
.logo-img {
    max-height: 100px;
    width: auto;
}

/* Logo Animation */
@keyframes logoFadeIn {
  0% {
    opacity: 0;
    transform: scale(0.95);
  }
  100% {
    opacity: 1;
    transform: scale(1);
  }
}

.logo-img {
  opacity: 0;
  animation: logoFadeIn 1.2s ease-out forwards;
  transform-origin: center;
  transition: transform 0.3s ease;
}

/* Optional: Hover Flair (slight pop) */
.logo-img:hover {
  transform: scale(1.05);
}



/* ========== Hero Section ========== */
.hero-rotator {
    position: relative;
    width: 100%;
    height: 500px; /* Set consistent height */
    min-height: 400px;
    overflow: hidden;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;  /* Force full height */
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 0;
}

.hero-slide.active {
    opacity: 1;
    position: relative;
    z-index: 1;
}

.hero-rotator, .hero-slide {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
}


.hero-text {
    background: rgba(0, 0, 0, 0.5);
    padding: 20px 30px;
    text-align: center;
    color: #ffffff;
    border-radius: 10px;
    z-index: 2;
    position: relative;
}

.cta-button {
    display: inline-block;
    margin-top: 15px;
    padding: 10px 20px;
    border: 2px solid #EF8354;
    color: #EF8354;
    text-decoration: none;
    box-shadow: 2px 2px 5px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    cursor: pointer;
}

.cta-button:hover {
    background-color: #EF8354;
    color: #ffffff;
}


.hero-dots {
    position: absolute;
    bottom: 20px;
    width: 100%;
    text-align: center;
    z-index: 5;
}

.hero-dots .dot {
    display: inline-block;
    height: 12px;
    width: 12px;
    margin: 0 6px;
    background-color: transparent;
    border: 2px solid #1E3D59; /* Navy Outline */
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.hero-dots .dot.active,
.hero-dots .dot:hover {
    background-color: #EF8354; /* Accent fill */
    transform: scale(1.2);
}


/* ========== Book Grid ========== */
.book-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(224px, 1fr));
    gap: 20px;
    padding: 20px;
    justify-items: center;
}

.book-item {
    width: 224px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    border-radius: 8px;
    overflow: hidden;
    position: relative;
}

.book-item img {
    width: 224px;
    height: 333px;
    display: block;
    border-radius: 8px 8px 0 0;
}

.book-item:hover,
.book-item:focus-within {
    transform: scale(1.05);
    box-shadow: 0 8px 16px rgba(0,0,0,0.2);
    background-color: #ffffff;
}

.book-item h3 {
    margin: 10px 0 0 0;
    font-size: 1rem;
    color: #2B2D42;
}

.view-all {
    display: block;
    text-align: center;
    margin-top: 20px;
    color: #EF8354;
    text-decoration: none;
}

.hidden-book,
.hidden-link {
    display: none;
}

/* Ribbons & Badges */
.badge-new-release,
.ribbon-new-release {
    background-color: #EF8354;
}

.badge-top-seller,
.ribbon-top-seller {
    background-color: #28a745;
}

/* ========== Badge with Glow and Smooth Hover ========== */
.book-item {
    position: relative;
    overflow: hidden;
}

/* Base Angled Badge Style */
.badge {
    position: absolute;
    top: 30px; /* Increased from 15px to 30px */
    left: -40px;
    transform: rotate(-45deg);
    width: 160px;
    text-align: center;
    padding: 6px 0;
    font-size: 0.75rem;
    font-weight: bold;
    color: white;
    text-transform: uppercase;
    border-radius: 4px;
    z-index: 10;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
    background: linear-gradient(135deg, rgba(255,255,255,0.1), transparent), #FF5733;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}


/* Specific Badge Colors */
.badge-new-release {
    background: linear-gradient(135deg, rgba(255,255,255,0.1), transparent), #EF8354; /* Your accent orange */
}

.badge-top-seller {
    background: linear-gradient(135deg, rgba(255,255,255,0.1), transparent), #28a745; /* Green */
}

/* Glow Effect on Image Hover */
.book-item:hover .badge {
    transform: rotate(-45deg) scale(1.1);
    box-shadow: 0 0 16px rgba(255, 255, 255, 0.8);
}



/* ============ ABOUT ============*/
#about {
    background-color: #E2E2E2;
    padding: 60px 20px;  /* Increased top/bottom spacing */
    text-align: center;
    line-height: 1.7;  /* Improved line spacing for readability */
    position: relative;
    background-color: #F8F4E3;
    background-image: url('https://www.transparenttextures.com/patterns/paper-fibers.png');
    background-repeat: repeat;
    background-size: auto;
    padding: 60px 20px; /* Adjust spacing as needed */
    text-align: center;
    box-shadow: inset 0 20px 20px -20px rgba(0,0,0,0.1),
                inset 0 -20px 20px -20px rgba(0,0,0,0.1);
}

#about h2 {
    font-size: 2rem;
    margin-bottom: 20px;
    color: #2B2D42;
}

#about h3 {
    font-size: 1.5rem;
    margin-top: 30px;   /* Clear separation between sections */
    margin-bottom: 15px;
    color: #1E3D59;
}

#about p {
    max-width: 800px;
    margin: 0 auto 20px auto;
    font-size: 1rem;
    color: #2B2D42;
    padding: 0 10px;  /* Small padding for mobile comfort */
}

.about-header-img {
    max-width: 100%;
    max-height: 200px;  /* LIMIT height to 200px */
    height: auto;
    margin-bottom: 20px;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

#about::before,
#about::after {
    content: "";
    position: absolute;
    left: 0;
    width: 100%;
    height: 30px;
    pointer-events: none;
    z-index: 1;
}

#about::before {
    top: 0;
    background: linear-gradient(to bottom, rgba(0,0,0,0.1), transparent);
}

#about::after {
    bottom: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.1), transparent);
}

#about, #contact {
    background-color: #E2E2E2;
}



/* ========== Testimonials ========== */

.testimonial-slider {
    position: relative;
    height: 100px;
    overflow: hidden;
    text-align: center;
}

.testimonial {
    position: absolute;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    width: 100%;
    font-style: italic;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.3);
    color: #ffffff;  /* Ensure testimonials are white */
    font-size: 1.1rem;
}

.testimonial.active {
    opacity: 1;
    position: relative;
}

#testimonials {
    background-color: #F4A261;  /* Accent Color */
    color: #ffffff;  /* White text for contrast */
    padding: 60px 20px;
    text-align: center;
}

#testimonials h2 {
    color: #ffffff;
    margin-bottom: 30px;
    font-size: 2rem;
}

.testimonial-slider {
    position: relative;
    height: 100px;
    overflow: hidden;
    text-align: center;
}



.testimonial.active {
    opacity: 1;
    position: relative;
}



/* ========== Contact Section ========== */
section {
    padding: 40px 20px;
    text-align: center;
}

#contact {
    position: relative;
    background-color: #F8F4E3;
    background-image: url('https://www.transparenttextures.com/patterns/paper-fibers.png');
    background-repeat: repeat;
    background-size: auto;
    padding: 60px 20px;
    text-align: center;
    box-shadow: inset 0 20px 20px -20px rgba(0,0,0,0.1),
                inset 0 -20px 20px -20px rgba(0,0,0,0.1);
}

#contact::before,
#contact::after {
    content: "";
    position: absolute;
    left: 0;
    width: 100%;
    height: 30px;
    pointer-events: none;
    z-index: 1;
}

#contact::before {
    top: 0;
    background: linear-gradient(to bottom, rgba(0,0,0,0.1), transparent);
}

#contact::after {
    bottom: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.1), transparent);
}



.contact-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding: 20px;
    max-width: 500px;
    margin: 0 auto;
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
    padding: 12px 15px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 1rem;
    width: 100%;
    box-sizing: border-box;
    background-color: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);  /* Increased shadow */
    transition: box-shadow 0.3s ease, border-color 0.3s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: #EF8354;
    box-shadow: 0 6px 20px rgba(239, 131, 84, 0.4);  /* Stronger glow on focus */
    outline: none;
}

.contact-form textarea {
    resize: vertical;
    min-height: 150px;
}


.contact-form button {
    padding: 12px 20px;
    border: 2px solid #EF8354;
    background: none;
    color: #EF8354;
    font-size: 1rem;
    border-radius: 8px;
    cursor: pointer;
    box-shadow: 2px 2px 5px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.contact-form button:hover {
    background: #EF8354;
    color: #ffffff;
}

.form-response {
    margin-top: 10px;
    padding: 12px;
    border: 2px solid #EF8354;
    background-color: #fff8f0;
    color: #28a745;
    font-weight: bold;
    border-radius: 6px;
    box-shadow: 1px 1px 4px rgba(0,0,0,0.05);
    display: none;
}

.form-response.show {
    display: block;
}

button:disabled {
  background-color: #ccc;
  cursor: not-allowed;
  opacity: 0.6;
}

/* Social Buttons */
.social-buttons {
    margin-top: 20px;
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.social-btn {
    padding: 10px 20px;
    border: 2px solid #EF8354;
    color: #EF8354;
    text-decoration: none;
    border-radius: 5px;
    box-shadow: 2px 2px 5px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.social-btn:hover {
    background-color: #EF8354;
    color: #ffffff;
}

/* Nav Social Icon Style */
.nav-links .nav-social-icon {
  font-size: 1rem;  /* Adjust icon size */
  color: #000;  /* Match your nav text color */
  padding-left: 8px;
  transition: color 0.3s ease;
}

.nav-links .nav-social-icon:hover {
  color: #1877F2;  /* Facebook blue on hover */
}



/* ========== Footer ========== */
footer {
    text-align: center;
    padding: 5px;
    background: #E2E2E2;
    padding: 20px 0 40px 0;  /* 20px top, 0 sides, 40px bottom */
}

.footer-text,
.footer-links a {
    font-size: 0.85rem;
    margin: 5px;
    text-decoration: none;
    color: #2B2D42;
}

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


.footer-logo {
    margin-top: 10px;
    text-align: center;
}

.footer-logo img {
    width: 30px;  /* Very small */
    height: auto;
    opacity: 0.6;
    transition: opacity 0.3s ease;
}

.footer-logo img:hover {
    opacity: 1;  /* Slightly brighter on hover */
}

.footer-logo-link {
    display: inline-block;
    margin-top: 10px;
}

.footer-logo {
    width: 40px;  /* Small, subtle */
    height: auto;
    transition: transform 0.6s ease;
}

.footer-logo:hover {
    transform: rotate(360deg);
}



/* ========== Back to Top Button ========== */
#backToTop {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1000;
    width: 50px;
    height: 50px;
    background: transparent;
    border: none;
    cursor: pointer;
    display: none; /* Initially hidden */
    opacity: 0;
    transition: opacity 0.4s ease, transform 0.4s ease;
}

#backToTop img {
    width: 100%;
    height: 100%;
    transition: transform 0.5s ease;
}

#backToTop:hover img {
    transform: rotate(360deg);
}

/* Show Button Class (use in JS) */
#backToTop.show {
    display: block;
    opacity: 1;
}


/* =========== MEDIA QUERIES ============*/

@media (max-width: 768px) {
    .menu-toggle { display: block; }
    .logo-img { height: 40px; }
    .nav-links {
        list-style: none;  /* Ensures individual list items have no bullets */
        display: none;
        flex-direction: column;
        gap: 10px;
        background-color: #ffffff;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        padding: 15px 20px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.1);
        border-top: 1px solid #ddd;
        text-align: center;
        z-index: 999;
    }
    .nav-links.show {
        display: flex;
        animation: dropdownFade 0.3s ease-in-out;
    }
    @keyframes dropdownFade {
        from { opacity: 0; transform: translateY(-10px); }
        to { opacity: 1; transform: translateY(0); }
    }
}

@media (max-width: 768px) {
    .hero-rotator {
        height: 300px;
    }
}
