/* =========================
   CSS Variables
   ========================= */
:root {
    --main-bg: #fff;
    --main-text: #222;
    --nav-bg: #ff6200;
    --nav-text: white;
    --nav-shadow: 0 0 15px 5px rgb(70, 70, 70);
    --accent: #FF914C;
    --accent-hover: #ffb07b;
    --card-bg: #fff;
    --card-radius: 12px;
    --card-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    --card-shadow-hover: 0 8px 20px rgba(0, 0, 0, 0.10);
    --feature-bg: #fff;
    --feature-box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    --feature-radius: 12px;
    --feature-border: #1d4ed8;
    --feature-outline: 2px solid #1d4ed8;
    --feature-bg-alt: #f3f4f6;
    --testimonial-bg: #f9f9f9;
    --testimonial-border: #1d4ed8;
    --btn-border: #105cd4;
    --btn-bg: transparent;
    --btn-text: #105cd4;
    --btn-radius: 10px;
    --cta-bg: #1d4ed8;
    --cta-text: #fff;
    --cta-bg-hover: #1e40af;
    --footer-bg: #111827;
    --footer-text: #cbd5e1;
    --bottom-info-icon: rgb(39, 39, 39);
    --bottom-info-icon-hover: rgb(98, 98, 98);
    --card-border: transparent;
}

/* =========================
   Dark Mode Variables
   ========================= */
:root {
    --main-bg-dark: #181824;
    --main-text-dark: #f3f3f3;
    --nav-bg-dark: #1a1333;
    --card-bg-dark: #23243a;
    --card-shadow-dark: 0 4px 16px rgba(0, 0, 0, 0.25);
    --card-shadow-hover-dark: 0 8px 24px rgba(0, 0, 0, 0.35);
    --feature-bg-dark: #23243a;
    --feature-box-shadow-dark: 0 4px 16px rgba(0, 0, 0, 0.18);
    --feature-bg-alt-dark: #23243a;
    --testimonial-bg-dark: #23243a;
    --testimonial-border-dark: #FF914C;
    --btn-border-dark: #FF914C;
    --btn-bg-dark: transparent;
    --btn-text-dark: #FF914C;
    --cta-bg-dark: #FF914C;
    --cta-text-dark: #23243a;
    --cta-bg-hover-dark: #ffb07b;
    --footer-bg-dark: #23243a;
    --footer-text-dark: #f3f3f3;
    --bottom-info-icon-dark: #f3f3f3;
    --bottom-info-icon-hover-dark: #FF914C;
    --btn-primary-dark: #4CAF50;
    --card-border-dark: transparent;
}

/* =========================
   Base Styles
   ========================= */
* {
    margin: 0;
    padding: 0;
    outline: none;
    box-sizing: border-box;
    font-family: "Inter", sans-serif;
}

/* =========================
   Body
   ========================= */
body {
    width: 100%;
    padding-top: 10vh;
    position: relative;
    background: var(--main-bg);
    color: var(--main-text);
    transition: background 0.2s, color 0.2s;
}

nav .dropdown-content a:hover {
    color: darkblue !important;
    border-radius: 10px;
}

:root {
    --w: 285px;
    --h: 400px;
    --dur: 12s;
}

.flip-container {
    width: var(--w);
    height: var(--h);
    perspective: 1000px;
    margin: 32px;
    position: relative;
    transition: .5s;
}

.front,
.back {
    position: absolute;
    inset: 0;
    backface-visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    border-radius: 10px;
    font: 600 1rem/1.2 system-ui, -apple-system, "Segoe UI", Roboto;
    transition: .5s;
}

.front {
    color: white;
    height: var(--h);
    width: var(--w);
}

.back {
    background: linear-gradient(135deg, #ff5252, #ff8a65);
    color: white;
    transform: rotateY(180deg);
    padding: 1rem;
    height: var(--h);
    width: var(--w);
    font-weight: 400;
}
.back strong{
    text-align: center;
    font-weight: 200;
    font-size: 30px;
}
/* THE KEY: flip whenever anything inside the container has focus */
.flip-container:focus-within .card {
    transform: rotateY(180deg);
    transition: .5s;
}

/* style the clickable <a> so it looks like a link but doesn't navigate */
.flip-link {
    cursor: pointer;
    text-decoration: underline;
    color: inherit;
    background: none;
    border: none;
    font: inherit;
    padding: 0;
    margin: 0;
}

/* ensure the <a> is keyboard-focusable */
.flip-link:focus {
    outline: 3px solid rgba(255, 255, 255, .25);
    outline-offset: 4px;
}

/* remove default outline on container */
.flip-container {
    outline: none;
}

/* =========================
   Navigation Bar
   ========================= */
nav {
    width: 100%;
    height: 10vh;
    background-color: var(--nav-bg);
    position: fixed;
    top: 0;
    z-index: 99999;
    display: flex;
}

.logo {
    width: 55%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding-left: 5%;
    color: var(--nav-text);
    flex-direction: row;
}

.links {
    width: 45%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: row;
}

.links a {
    padding: 10px;
    color: var(--nav-text);
    text-decoration: none;
    cursor: pointer;
    transition: color 0.2s;
}

.links ul {
    margin-bottom: 0;
}
.links a:hover{
    color: #FF914C;
}
.links ul .active_link {
    color: #181824 !important;
}

body.dark-mode .links ul .active_link {
    color: #181824 !important;
}

.back-btn {
    position: fixed;
    top: 100px;
    display: inline-block;
    text-decoration: none;
    margin: 10px;
    padding: 5px 10px;
    border: 2px solid var(--btn-border);
    border-radius: var(--btn-radius);
    background-color: var(--btn-bg);
    color: var(--btn-text);
    transition: background 0.2s, color 0.2s, border 0.2s;
}

.back-btn:hover {
    background-color: var(--btn-border);
    color: #fff;
    border-color: var(--btn-border);
}

.btn-outline-primary {
    background: transparent !important;
    color: #0b5ed7 !important;
    width: 100% !important;
}


.btn-outline-primary:hover {
    background: transparent !important;
    color: white !important;
    border-color: #FF914C !important;
}

/* =========================
   Main Container & Cards
   ========================= */
.container {
    width: 100%;
    height: fit-content;
    padding: 15px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 310px));
    justify-content: center;
}

.card {
    border-color: var(--card-border) !important;
    background: var(--main-bg);
    color: var(--main-text);
    transition: background 0.2s, color 0.2s, border 0.2s;
    position: relative;
    transform-style: preserve-3d;
    transition: transform var(--dur) ease;
    width: var(--w);
    height: var(--h);
    transition: .5s;
}

.flip-container .card .card-title {
    font-size: 30px;
}

.flip-container .card-body {
    font-family: "EB Garamond", serif;
    font-weight: 300;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border: 1px solid grey;
    border-bottom-left-radius: 10px;
    border-bottom-right-radius: 10px;
    color: rgb(32, 32, 32);
    transition: .1s;
}

body.dark-mode .flip-container .card-body {
    background-color: var(--card-bg-dark);
    font-weight: 100;
    border: none;
    color: white;
    transition: .1s;
}

/* =========================
   Dark Mode Styles
   ========================= */
body.dark-mode {
    background: var(--main-bg-dark);
    color: var(--main-text-dark);
}

body.dark-mode .logo {
    color: var(--nav-text-dark);
}

body.dark-mode .links a {
    color: var(--nav-text-dark);
}

body.dark-mode .links a:hover {
    color: var(--nav-accent-dark);
}

body.dark-mode .card {
    background: var(--main-bg-dark);
    color: var(--main-text-dark);
    border-color: var(--card-border-dark) !important;
}

body.dark-mode .btn-outline-primary:hover {
    border-color: var(--btn-primary-dark) !important;
}

body.dark-mode .back-btn {
    border: 2px solid var(--btn-border-dark);
    background-color: var(--btn-bg-dark);
    color: var(--btn-text-dark);
}

body.dark-mode .back-btn:hover {
    background-color: var(--btn-border-dark);
    color: #fff;
    border-color: var(--btn-border-dark);
}

.hover-fill-bottom {
    position: relative;
    overflow: hidden;
    z-index: 1;
    transition: color 0.3s ease;
}
body.dark-mode .hover-fill-bottom{
    color: white !important;
    border-color: white;
}
.hover-fill-bottom::before {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    height: 0%;
    width: 100%;
    background-color: #FF914C;
    z-index: -1;
    transition: height 0.3s ease;
}

body.dark-mode .hover-fill-bottom::before {
    background-color: #4CAF50;
}


.hover-fill-bottom:hover::before {
    height: 100%;
}

/* .flip-container:hover .card {
    transform: rotateY(180deg);
} */