:root {
    --brand: #d9185f;
    --ink: #fad4d8;
    --header-h: 72px;
    --zoom: 1.2;
}

/* Fonts (optional – your existing CityBank faces) */
@font-face {
    font-family: "CityBank";
    src: url("webfonts/CityBank-Regular-V2.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "CityBank";
    src: url("webfonts/CityBank-SemiBold-V2.woff2") format("woff2");
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "CityBank";
    src: url("webfonts/CityBank-Bold-V2.woff2") format("woff2");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

html,
body {
    height: 100%;
}
body {
    margin: 0;
    background: var(--brand);
    color: var(--ink);
    font-family: "CityBank", system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Noto Sans", sans-serif;
}

/* Header */
.brand-bar {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: start;
    padding: 16px 32px;
    position: relative;
    z-index: 10;
    height: auto; /* Ensure height is based on content, not fixed to 100% */
}

.logo-left {
    max-height: clamp(4rem, 7vw, 5.3rem); /* scales ~64px → 85px */
    width: auto;
    position: absolute;
    margin: clamp(1.5rem, 5vw, 2.63rem) /* top/bottom: ~24px → 42px */ clamp(2rem, 6vw, 3.88rem); /* left/right: ~32px → 62px */
}

.logo-left {
    max-height: clamp(4rem, 6.5vw, 5.06rem);
}

.logo-center {
    max-height: clamp(11rem, 14vw, 11.25rem); /* scales ~160px → 260px */
    width: auto;
    margin: clamp(0.5rem, 3vw, 1.5rem) 0; /* top: 24px → 40px */
    justify-self: center;
    position: absolute;
}

.logo-left {
    justify-self: start;
}

.logo-right {
    justify-self: end;
    position: absolute;
    margin-top: 45px;
    margin-right: 30px;
}

@media (max-width: 768px) {
    /* .brand-bar {
        grid-template-columns: 1fr 1fr 1fr;
        padding: 12px 16px;
    }
    .logo-left,
    .logo-right {
        max-height: 100px;
        position: absolute;
        margin: 5px;
    } */

    .logo-left {
        justify-self: center;
    }

    .logo-center {
        margin-top: 70px;
    }
    .btn-container {
        margin-top: 80px;
    }

    /* Adjusting the .logo-right positioning */
    .logo-right {
        position: fixed;
        left: 50%;
        bottom: 10%;
        transform: translateX(-50%);
        display: flex;
        gap: 8px;
    }
}

/* From Uiverse.io by JaydipPrajapati1910 */

.btn-container {
    display: table-cell;
    vertical-align: middle;
    text-align: center;
}

.btn-color-mode-switch {
    display: inline-block;
    margin: 0px;
    position: relative;
}

.btn-color-mode-switch > label.btn-color-mode-switch-inner {
    margin: 0px;
    width: 140px;
    height: 40px;
    background-color: #fad4d8;
    border-radius: 26px;
    overflow: hidden;
    position: relative;
    transition: all 0.3s ease;
    /*box-shadow: 0px 0px 8px 0px rgba(17, 17, 17, 0.34) inset;*/
    display: block;
}

.btn-color-mode-switch > label.btn-color-mode-switch-inner:before {
    content: attr(data-on);
    position: absolute;
    font-size: 15px;
    font-weight: 600;
    top: 9px;
    right: 20px;
    color: #222;
    margin-left: -5px;
}

.btn-color-mode-switch > label.btn-color-mode-switch-inner:after {
    content: attr(data-off);
    width: 70px;
    height: 25px;
    background: #d9185f;
    border-radius: 26px;
    position: absolute;
    font-size: 15px;
    display: flex;
    justify-content: center;
    left: 2px;
    top: 2px;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0px 0px 6px -2px #111;
    padding: 5px 0px;
    color: #ffffff;
    font-weight: 600;
}

.btn-color-mode-switch input[type="checkbox"] {
    cursor: pointer;
    width: 50px;
    height: 25px;
    opacity: 0;
    position: absolute;
    top: 0;
    z-index: 1;
    margin: 0px;
}

.btn-color-mode-switch input[type="checkbox"]:checked + label.btn-color-mode-switch-inner {
    background-color: #fad4d8;
}

.btn-color-mode-switch input[type="checkbox"]:checked + label.btn-color-mode-switch-inner:after {
    content: attr(data-on);
    left: 68px;
}

.btn-color-mode-switch input[type="checkbox"]:checked + label.btn-color-mode-switch-inner:before {
    content: attr(data-off);
    right: auto;
    left: 20px;
}

/* Stage / shell */
.stage {
    position: relative;
    height: calc(100svh - var(--header-h));
    display: grid;
    place-items: center;
    overflow: hidden;
    /* transform: scale(var(--zoom)); */
}

.flip-shell {
    position: relative;
    width: min(1200px, 94vw);
    aspect-ratio: 970/337;
    max-height: min(55svh, 460px);
    display: flex;
    align-items: center;
    justify-content: center;
}
.flip-book {
    width: 100%;
    height: 100%;
}
.page {
    border-radius: 8px;
    box-shadow: 0 12px 26px rgba(0, 0, 0, 0.25);
    overflow: hidden;
}
.page-img {
    background: #fff center/cover no-repeat;
}

/* Background images */
.page-front {
    background-image: url("img/front-new.png");
}
.page-back {
    background-image: url("img/Back.png");
}
.page-white {
    background-image: url("img/White.png");
}
/* .page-step-1,
.page-step-2,
.page-step-3,
.page-step-4,
.page-step-5,
.page-step-6 {
    background-image: url("img/Step 1_E.png");
} */

/* Cover form overlay */
/* From Uiverse.io by Akshdeep74644 */

.step-image {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ensures the image covers the entire container */
    object-position: center; /* Centers the image within the container */
    background-repeat: no-repeat; /* Prevents the background image from repeating */
}

.overlay-form {
    position: relative;
    width: 100%;
    height: 80%;
    display: flex; /* side by side */
    align-items: center; /* vertical center */
    justify-content: flex-start; /* push content to left side */
    margin: 22px 35px;
}

@media (max-width: 700px) {
    .overlay-form {
        margin: 40px 0px;
        height: 70%;
        transform: scale(0.92); /* ✅ correct syntax */
        transform-origin: top center; /* optional: control where it scales from */
    }
}

.input-container {
    display: flex;
    flex-direction: column;
    gap: 0.5rem; /* spacing between inputs */
    max-width: 280px; /* adjust width as needed */
}

/* From Uiverse.io by satyamchaudharydev */
.form {
    --width-of-input: 200px;
    --border-height: 1px;
    --border-before-color: rgb(255, 255, 255);
    --border-after-color: var(--ink);
    --input-hovered-color: var(--ink);
    position: relative;
    width: var(--width-of-input);
}

/* styling of Input */
.input {
    color: #fff;
    font-size: 0.8rem;
    background-color: transparent;
    width: 100%;
    box-sizing: border-box;
    padding-inline: 0.5em;
    padding-block: 0.7em;
    border: none;
    border-bottom: var(--border-height) solid var(--border-before-color);
}

.input::placeholder {
    color: #fff; /* pure white */
    opacity: 1; /* ensure it’s not faded in Firefox */
}

/* styling of animated border */
.input-border {
    position: absolute;
    background: var(--border-after-color);
    width: 0%;
    height: 2px;
    bottom: 0;
    left: 0;
    transition: 0.3s;
}
/* Hover on Input */
input:hover {
    background: transparent;
}

input:focus {
    outline: none;
}
/* here is code of animated border */
input:focus ~ .input-border {
    width: 100%;
}

@media (max-width: 700px) {
    /* From Uiverse.io by satyamchaudharydev */
    .form {
        --width-of-input: 150px;
    }

    .input {
        font-size: 0.6rem;
    }
}

/* === if you want to do animated border on typing === */
/* remove input:focus code and uncomment below code */
/* input:valid ~ .input-border{
  width: 100%;
} */

/* From Uiverse.io by alexroumi */
.button {
    padding: 3px 7px;
    border-radius: 15px;
    border: solid 1px #e8e8e8;
    border-radius: 15px;
    color: #d9185f;
    z-index: 1;
    background: #e8e8e8;
    position: relative;
    font-weight: 1000;
    font-size: 15px;
    -webkit-box-shadow: 4px 8px 19px -3px rgba(0, 0, 0, 0.27);
    box-shadow: 4px 8px 19px -3px rgba(0, 0, 0, 0.27);
    transition: all 250ms;
    overflow: hidden;
}

.button::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 0;

    background-color: #d9185f;
    z-index: -1;
    -webkit-box-shadow: 4px 8px 19px -3px rgba(0, 0, 0, 0.27);
    box-shadow: 4px 8px 19px -3px rgba(0, 0, 0, 0.27);
    transition: all 250ms;
}

.button:hover {
    color: #e8e8e8;
}

.button:hover::before {
    width: 100%;
}

.nav-btn {
    position: absolute; /* Position the button absolutely within the parent */
    bottom: 10px; /* Adjust bottom position as needed */
    right: 20px;

    background: #fff;
    border: 0;
    border-radius: 999px;
    padding: 10px 20px; /* Adjust padding to fit the text in one line */
    font-weight: 600;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.25);
    z-index: 999999; /* Ensure the button is on top */
    display: inline-block;
    margin-top: 10px;
    text-align: center;
    white-space: nowrap; /* Prevent text from breaking into multiple lines */
    max-width: 100%; /* Prevent button from stretching too much */
}

.nav-btn:hover {
    background-color: #d9185f; /* Change background on hover */
    color: #fff; /* Change text color on hover */
    transform: scale(1.05); /* Slightly scale up the button */
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35); /* Increase shadow on hover */
    cursor: pointer; /* Change cursor to pointer */
}

/* Arrows overlay */
 /* Arrows overlay */
.nav-arrows {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transform: translateY(-50%);
    z-index: 20;
}

.nav-arrows .left-edge {
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
}

.nav-arrows .right-edge {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
}

.nav-arrows button {
    pointer-events: auto;
    width: 48px;
    height: 48px;
    background: none;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.nav-arrows button::before {
    content: "";
    display: block;
    width: 14px;
    height: 14px;
    border-top: 3px solid #fff;
    border-right: 3px solid #fff;
}

.nav-arrows .left-edge::before {
    transform: rotate(-135deg);
}

.nav-arrows .right-edge::before {
    transform: rotate(45deg);
}


/* Pager dots */
.pager {
    position: absolute;
    left: 50%;
    bottom: 5%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
}
.pager .dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.6);
}
.pager .dot.active {
    background: #fff;
}

@media (max-width: 700px) {
    .page-white {
        background-image: none !important;
        background: transparent !important; /* optional: no fallback color */
        box-shadow: none !important; /* optional: remove shadow if empty */
    }

    .nav-btn { 
    right: 22%;
 
}
}

/* smooth center shift for covers */
.flip-shell .stf__wrapper {
    transition: transform 280ms ease;
}

/* While locked, disable UI controls */
.locked .nav-arrows button {
    pointer-events: none;
    opacity: 0.35;
    filter: grayscale(0.4);
}

.locked .pager {
    pointer-events: none;
    opacity: 0.35;
}

/* Optional: show "not allowed" when hovering flip area while locked */
.locked .flip-shell {
    cursor: not-allowed;
}

/* Style for story-line */
.story-line {
    font-size: 0.75rem; /* Adjust the font size as needed */
    font-weight: 400; /* Make the text bold */
    color: #fff; /* Text color */
    text-align: center;
    margin-left: auto;
    margin-right: auto; /* Center the text block */
    white-space: pre-wrap; /* Allow text to wrap properly */

    /* Position it at the bottom of the screen */
    position: absolute;
    left: 50%;
    bottom: 17%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    justify-content: center; /* center the content horizontally */
    align-items: center;

    margin: 0;
    padding: 10px 12px;
    max-width: 90vw; /* keep it readable */
    width: 100%;
}

@media (max-width: 768px) {
    .story-line {
        font-size: 0.65rem; /* Adjust font size for smaller screens */
        padding: 10 5px; /* Adjust padding for mobile devices */
        bottom: 30%;
    }
}

/* Disable navigation buttons and pager dots when disabled */
.nav-arrows button[disabled],
.pager .dot[disabled] {
    opacity: 0.4; /* Make them look disabled */
    cursor: not-allowed; /* Change cursor to indicate the element is not clickable */
    pointer-events: none; /* Disable interaction */
    display: none !important; /* Completely hide the elements */
}

/* While locked, disable UI controls */
.locked .nav-arrows button {
    pointer-events: none;
    opacity: 0.35;
    filter: grayscale(0.4);
    display: none !important; /* Hide buttons when locked */
}

.locked .pager {
    pointer-events: none;
    opacity: 0.35;
}

.locked .flip-shell {
    cursor: not-allowed; /* Show not-allowed cursor on the flip area while locked */
}

/* Overlay always on top; hidden until .show */
.modal-overlay {
    position: fixed;
    inset: 0;
    /* background: rgba(0, 0, 0, 0.55); */
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
    z-index: 9999;
    /* backdrop-filter: saturate(120%) blur(2px); */
}
.modal-overlay.show {
    opacity: 1;
    pointer-events: auto;
}

/* Card: no internal scrolling; size to content; responsive cap */
.modal-card {
    position: relative;
    background: #fff;
    border-radius: 16px;
    padding: 12px 12px 14px;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.35);
    width: min(92vw, 640px); /* responsive width */
    overflow: visible; /* no scrollbars inside */
}

/* Close (top-right) */
.modal-close {
    position: absolute;
    top: 6px;
    right: 6px;
    border: 0;
    background: transparent;
    font-size: 26px;
    line-height: 1;
    padding: 6px;
    cursor: pointer;
}

/* Loader centered block */
.loader {
    width: 56px;
    height: 56px;
    border: 6px solid #e9e9e9;
    border-top-color: #8a1b4d;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 24px auto;
}
@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Image scales down to fit viewport without scroll */
.result-img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 70vh; /* keeps full modal within viewport */
    object-fit: contain;
    border-radius: 10px;
}

/* Button Container Styling */
.modal-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 20px;
}

/* Base Button Styling */
.modal-actions .btn {
    padding: 7px 15px;
    border-radius: 30px;
    font-weight: bold;
    font-size: 12px;
    border: 2px solid transparent; /* Transparent border */
    background-color: var(--brand); /* Brand color */
    color: var(--ink); /* Ink color */
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease, transform 0.3s ease;
    cursor: pointer;
    gap: 10px; /* Space between icon and text */
}

.modal-actions .btn i {
    font-size: 12px; /* Icon size */
}

/* Hover Effect */
.modal-actions .btn:hover {
    background-color: var(--ink); /* Change to ink color on hover */
    color: var(--brand); /* Change text to brand color */
    transform: scale(1.05); /* Slightly scale the button on hover */
}

/* Share Button */
#shareBtn {
    background-color: var(--brand); /* Brand color */
}

#shareBtn:hover {
    background-color: var(--ink); /* Ink color on hover */
    color: var(--brand); /* Text color change on hover */
}

a {
    text-decoration: none;
}

/* Download Button */
#downloadBtn {
    background-color: var(--brand); /* Brand color */
}

#downloadBtn:hover {
    background-color: var(--ink); /* Ink color on hover */
    color: var(--brand); /* Text color change on hover */
}

.modal-overlay.hidden {
    display: none !important;
}

.hidden {
    display: none !important;
}

/* Modal Overlay */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
    z-index: 9999;
    /* backdrop-filter: blur(5px); */
}

.modal-overlay.show {
    opacity: 1;
    pointer-events: auto;
}

/* Modal Card */
.modal-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    width: 90%;
    max-width: 400px;
    padding: 20px;
    text-align: center;
    opacity: 1;
    transition: opacity 0.5s ease-out; /* Fade-out transition */
    animation: scaleIn 0.3s ease-out; /* Smooth scale-in effect */
}

/* Scale Animation for Modal Entry */
@keyframes scaleIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

/* Fade-out Animation for Modal */
@keyframes fadeOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

/* Fade-out class to be triggered when form is submitted */
.modal-card.fade-out {
    animation: fadeOut 0.5s ease-out forwards; /* Apply the fade-out animation */
}

/* Form Styling */
.front-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
    align-items: center; /* Ensure the form is centered */
}

/* Input Fields */
.input {
    width: 100%;
    padding: 12px;
    font-size: 16px;
    color: rgb(0, 0, 0);
    border: 1px solid #ccc;
    border-radius: 8px;
    background-color: #f9f9f9;
    transition: border 0.3s ease, box-shadow 0.3s ease;
}

/* Adjust Placeholder Visibility */
.input::placeholder {
    color: rgba(0, 0, 0, 0.742); /* Darker color for better visibility */
    font-size: 14px;
}

/* Focus State */
.input:focus {
    border-color: #d9185f;
    box-shadow: 0 0 5px rgba(217, 24, 95, 0.3);
    outline: none;
}

/* Submit Button */
.button {
    background: #d9185f;
    color: white;
    font-weight: 600;
    font-size: 16px;
    padding: 12px 24px;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.1s ease, background 0.3s ease;
}

.button:hover {
    background: #e73279;
}

.button:active {
    transform: translateY(2px);
}

.button:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(217, 24, 95, 0.4);
}

/* Responsive Adjustments */
@media (max-width: 480px) {
    .modal-card {
        padding: 18px;
    }

    .input {
        font-size: 14px;
    }

    .button {
        font-size: 14px;
        padding: 10px 18px;
    }
}

/* Centering Modal Card in the Overlay */
.opening-modal {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    /* background: rgba(0, 0, 0, 0.4); */
    z-index: 9999;
    padding: 20px;
    /* backdrop-filter: blur(5px); */
}

/* To ensure the modal does not get hidden immediately */
.opening-modal .modal-card {
    opacity: 1;
    transition: opacity 0.5s ease-out; /* Fade-out effect */
}

/* Input Container Styling */
.input-container {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-width: 280px; /* adjust width as needed */
    align-items: center;
}

 



/* Ensure input fields are large enough to prevent zooming on iOS */
input, textarea, select {
    font-size: 16px; /* Ensures no zooming on iOS devices */
}

/* Ensure the input fields do not zoom in on focus */
input:focus, textarea:focus {
    font-size: 16px; /* Maintain the same font size on focus */
}

 


/* Style for story-line */
.first_story-line {
    font-size: .75rem; /* Adjust the font size as needed */
    font-weight: 400; /* Make the text bold */
    color: #fff; /* Text color */
    text-align: center;
    margin-left: auto;
    margin-right: auto; /* Center the text block */
    white-space: pre-wrap; /* Allow text to wrap properly */

    /* Position it at the bottom of the screen */
    position: absolute;
    left: 50%;
    top: 25%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    justify-content: center; /* center the content horizontally */
    align-items: center;

    margin: 0;
    padding: 10px 12px;
    max-width: 90vw; /* keep it readable */
    width: 100%;
}

@media (max-width: 768px) {
    .first_story-line {
        top: 30%;
        font-size: 0.65rem; /* Adjust font size for smaller screens */
        padding: 10 5px; /* Adjust padding for mobile devices */
        
    }
}

footer{
    text-align: center;
    margin-top: 15px;
    font-size: 0.8rem;
     
}







/* Landscape fix: center smaller stage */
@media (orientation: landscape) and (max-height: 480px) {

    /* body{
        transform: scale(1);
    } */


    header{
        transform: scale(0.45); 
    }
    main {  
        padding-top: 10px;
        transform: scale(0.4); 
      }


      .story-line ,.first_story-line, footer{
         font-size: .35rem;
      }

      footer{
        /* padding-top: 10px; */
      }

      .modal-card{
        transform: scale(0.70); 
      }


      .nav-btn{
        /* margin-right:50px; */
        display: none;

      }
      
  }
  


 