/* mailrepo.de — Landing Page Styles
 * Brand colors derived from vautron.de:
 *   Primary:   #005885 (deep blue)
 *   Secondary: #009080 (teal)
 *   Accent:    #55B830 (green)
 *   Surface:   #f2f9f9 (light teal tint)
 */

/* ── CSS Variables ───────────────────────────────────────────────────────── */
:root {
    --landing-primary: #005885;
    --landing-primary-rgb: 0, 88, 133;
    --landing-secondary: #009080;
    --landing-accent: #55B830;
    --landing-surface: #f2f9f9;
    --landing-nav-bg: rgba(255, 255, 255, 0.92);
    --landing-section-alt-bg: var(--landing-surface);
    --landing-footer-bg: #001e2d;
    --landing-footer-text: #ccc;
    --landing-card-bg: #fff;
    --landing-card-border: rgba(0, 0, 0, 0.06);
}

[data-bs-theme="dark"] {
    --landing-primary: #3da5d9;
    --landing-primary-rgb: 61, 165, 217;
    --landing-secondary: #2ec4b6;
    --landing-accent: #7ed957;
    --landing-surface: #0d1b2a;
    --landing-nav-bg: rgba(13, 27, 42, 0.95);
    --landing-section-alt-bg: #0f2133;
    --landing-footer-bg: #060f18;
    --landing-footer-text: #8899aa;
    --landing-card-bg: #132234;
    --landing-card-border: rgba(255, 255, 255, 0.06);
}

/* ── Override Bootstrap primary ──────────────────────────────────────────── */
.btn-primary {
    --bs-btn-bg: var(--landing-primary);
    --bs-btn-border-color: var(--landing-primary);
    --bs-btn-hover-bg: #00476b;
    --bs-btn-hover-border-color: #00476b;
    --bs-btn-active-bg: #003a58;
    --bs-btn-active-border-color: #003a58;
}

[data-bs-theme="dark"] .btn-primary {
    --bs-btn-hover-bg: #2b8dbe;
    --bs-btn-hover-border-color: #2b8dbe;
    --bs-btn-active-bg: #2580ad;
    --bs-btn-active-border-color: #2580ad;
}

.btn-outline-primary {
    --bs-btn-color: var(--landing-primary);
    --bs-btn-border-color: var(--landing-primary);
    --bs-btn-hover-bg: var(--landing-primary);
    --bs-btn-hover-border-color: var(--landing-primary);
    --bs-btn-active-bg: var(--landing-primary);
    --bs-btn-active-border-color: var(--landing-primary);
}

.text-primary {
    color: var(--landing-primary) !important;
}

/* ── Body ────────────────────────────────────────────────────────────────── */
body {
    transition: background-color 0.2s ease, color 0.2s ease;
    overflow-x: hidden;
}

/* ── Navigation ──────────────────────────────────────────────────────────── */
.landing-nav {
    background: var(--landing-nav-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--landing-card-border);
    transition: background 0.3s ease;
    padding: 0.5rem 0;
}

.landing-nav .navbar-brand {
    font-size: 1.25rem;
    color: var(--landing-primary);
}

.landing-nav .nav-link {
    font-size: 0.9rem;
    font-weight: 500;
    padding: 0.5rem 0.75rem;
    transition: color 0.2s ease;
}

/* ── Hero ────────────────────────────────────────────────────────────────── */
.landing-hero {
    padding-top: 7rem;
    padding-bottom: 4rem;
}

.min-vh-75 {
    min-height: 75vh;
}

.landing-headline {
    line-height: 1.15;
    letter-spacing: -0.03em;
}

.landing-subline {
    font-size: 1.15rem;
    line-height: 1.7;
    max-width: 560px;
}

/* Hero visual — animated icon composition */
.landing-hero-visual {
    position: relative;
    height: 360px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Glow behind the icon stack */
.hero-glow {
    position: absolute;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--landing-primary) 0%, transparent 70%);
    opacity: 0.12;
    animation: glow-pulse 4s ease-in-out infinite;
}

/* Orbiting ring */
.hero-orbit {
    position: absolute;
    width: 300px;
    height: 300px;
    border: 2px dashed var(--landing-primary);
    border-radius: 50%;
    opacity: 0.15;
    animation: orbit-spin 24s linear infinite;
}

.orbit-dot {
    position: absolute;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--landing-primary);
}

.orbit-dot-1 {
    top: -5px;
    left: 50%;
    transform: translateX(-50%);
}

.orbit-dot-2 {
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
}

.orbit-dot-3 {
    top: 50%;
    right: -5px;
    transform: translateY(-50%);
}

/* Main icons */
.hero-icon-stack {
    position: relative;
    display: inline-block;
    z-index: 2;
}

.hero-icon-bg {
    font-size: 12rem;
    color: var(--landing-primary);
    opacity: 0.12;
    animation: float 6s ease-in-out infinite;
}

.hero-icon-fg {
    position: absolute;
    font-size: 5rem;
    color: var(--landing-primary);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: pulse 3s ease-in-out infinite;
}

/* Floating particles */
.hero-particles {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.particle {
    position: absolute;
    font-size: 1.5rem;
    color: var(--landing-secondary);
    opacity: 0.5;
}

.particle-1 {
    top: 10%;
    left: 5%;
    animation: float-particle 7s ease-in-out infinite;
}

.particle-2 {
    top: 15%;
    right: 10%;
    animation: float-particle 5s ease-in-out 1s infinite;
}

.particle-3 {
    bottom: 15%;
    left: 10%;
    animation: float-particle 6s ease-in-out 2s infinite;
}

.particle-4 {
    bottom: 10%;
    right: 5%;
    animation: float-particle 8s ease-in-out 0.5s infinite;
}

@keyframes glow-pulse {

    0%,
    100% {
        transform: scale(1);
        opacity: 0.12;
    }

    50% {
        transform: scale(1.15);
        opacity: 0.2;
    }
}

@keyframes orbit-spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-16px);
    }
}

@keyframes pulse {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }

    50% {
        transform: translate(-50%, -50%) scale(1.08);
        opacity: 0.85;
    }
}

@keyframes float-particle {

    0%,
    100% {
        transform: translateY(0) rotate(0deg);
        opacity: 0.5;
    }

    25% {
        transform: translateY(-12px) rotate(5deg);
        opacity: 0.7;
    }

    50% {
        transform: translateY(-6px) rotate(-3deg);
        opacity: 0.4;
    }

    75% {
        transform: translateY(-14px) rotate(2deg);
        opacity: 0.65;
    }
}

/* ── Sections ────────────────────────────────────────────────────────────── */
.landing-section {
    position: relative;
}

.landing-section-alt {
    background: var(--landing-section-alt-bg);
}

/* ── Feature cards ───────────────────────────────────────────────────────── */
.landing-feature-card {
    background: var(--landing-card-bg);
    border: 1px solid var(--landing-card-border) !important;
    border-radius: 1rem;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.landing-feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(var(--landing-primary-rgb), 0.1) !important;
}

.feature-icon-wrapper {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.75rem;
    background: rgba(var(--landing-primary-rgb), 0.08);
    color: var(--landing-primary);
}

/* ── Steps ───────────────────────────────────────────────────────────────── */
.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--landing-primary);
    color: #fff;
    font-weight: 700;
    font-size: 1.25rem;
}

/* ── Security badges ─────────────────────────────────────────────────────── */
.security-badge-card {
    background: var(--landing-card-bg);
    border: 1px solid var(--landing-card-border);
    transition: transform 0.2s ease;
}

.security-badge-card:hover {
    transform: scale(1.04);
}

/* ── Pricing ─────────────────────────────────────────────────────────────── */
.landing-pricing-highlight {
    border: 2px solid var(--landing-primary) !important;
    position: relative;
}

.landing-pricing-highlight .card-body {
    background: var(--landing-card-bg);
}

/* ── CTA ─────────────────────────────────────────────────────────────────── */
.landing-cta {
    background: linear-gradient(135deg,
            rgba(var(--landing-primary-rgb), 0.04) 0%,
            rgba(var(--landing-primary-rgb), 0.08) 100%);
}

/* ── Footer ──────────────────────────────────────────────────────────────── */
.landing-footer {
    background: var(--landing-footer-bg);
    color: var(--landing-footer-text);
}

.landing-footer a {
    color: var(--landing-footer-text) !important;
    transition: color 0.2s ease;
}

.landing-footer a:hover {
    color: #fff !important;
}

.landing-footer .text-body-secondary {
    color: var(--landing-footer-text) !important;
}

.landing-footer h6 {
    color: #fff;
}

.landing-footer hr {
    border-color: rgba(255, 255, 255, 0.1);
}

/* ── Smooth scrolling ────────────────────────────────────────────────────── */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

/* ── Responsive ──────────────────────────────────────────────────────────── */
@media (max-width: 991.98px) {
    .landing-hero {
        padding-top: 5.5rem;
        padding-bottom: 2rem;
        text-align: center;
    }

    .landing-headline {
        font-size: 2.2rem;
    }

    .landing-subline {
        margin-left: auto;
        margin-right: auto;
    }

    .min-vh-75 {
        min-height: auto;
    }
}

@media (max-width: 575.98px) {
    .landing-headline {
        font-size: 1.8rem;
    }

    .landing-hero .btn-lg {
        width: 100%;
    }

    .landing-hero .d-flex.gap-3 {
        flex-direction: column;
    }
}

/* ── Fade-in animation ───────────────────────────────────────────────────── */
.landing-fade-in {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.landing-fade-in.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ── Crypto-Flow Animation ───────────────────────────────────────────────── */
.crypto-flow-section {
    background: var(--landing-section-alt-bg);
    overflow: hidden;
}

.crypto-flow {
    position: relative;
    padding: 2rem 0;
}

/* Horizontal beam connecting all nodes (desktop only) */
.flow-beam {
    display: none;
}

@media (min-width: 768px) {
    .flow-beam {
        display: block;
        position: absolute;
        top: 60px;
        left: 10%;
        right: 10%;
        height: 2px;
        z-index: 0;
    }

    .flow-beam-track {
        position: relative;
        width: 100%;
        height: 100%;
        background: rgba(var(--landing-primary-rgb), 0.12);
        border-radius: 1px;
        overflow: hidden;
    }

    .flow-beam-pulse {
        position: absolute;
        top: -1px;
        left: -20%;
        width: 20%;
        height: 4px;
        border-radius: 2px;
        background: linear-gradient(90deg,
                transparent 0%,
                var(--landing-primary) 40%,
                var(--landing-secondary) 60%,
                transparent 100%);
        animation: beam-travel 3s ease-in-out infinite;
    }
}

@keyframes beam-travel {
    0% {
        left: -20%;
        opacity: 0;
    }

    10% {
        opacity: 1;
    }

    90% {
        opacity: 1;
    }

    100% {
        left: 100%;
        opacity: 0;
    }
}

/* Node grid layout */
.flow-nodes {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    position: relative;
    z-index: 1;
}

@media (min-width: 768px) {
    .flow-nodes {
        flex-direction: row;
        justify-content: space-between;
        gap: 0;
    }
}

/* Individual node */
.flow-node {
    text-align: center;
    flex: 1;
    max-width: 220px;
    opacity: 0;
    transform: translateY(30px) scale(0.9);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.crypto-flow-section.is-visible .flow-node[data-flow="1"] {
    transition-delay: 0.1s;
}

.crypto-flow-section.is-visible .flow-node[data-flow="2"] {
    transition-delay: 0.3s;
}

.crypto-flow-section.is-visible .flow-node[data-flow="3"] {
    transition-delay: 0.5s;
}

.crypto-flow-section.is-visible .flow-node[data-flow="4"] {
    transition-delay: 0.7s;
}

.crypto-flow-section.is-visible .flow-node {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* Node ring — container for icon + SVG orbit */
.flow-node-ring {
    position: relative;
    width: 120px;
    height: 120px;
    margin: 0 auto 1rem;
}

.flow-node-icon {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.4rem;
    color: var(--landing-primary);
    z-index: 2;
    transition: transform 0.3s ease;
}

.flow-node:hover .flow-node-icon {
    transform: scale(1.15);
}

/* Glow behind icon on hover */
.flow-node-icon::before {
    content: '';
    position: absolute;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(var(--landing-primary-rgb), 0.2) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.flow-node:hover .flow-node-icon::before {
    opacity: 1;
}

/* SVG ring animation */
.flow-ring-svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.ring-track {
    fill: none;
    stroke: rgba(var(--landing-primary-rgb), 0.08);
    stroke-width: 2;
}

.ring-arc {
    fill: none;
    stroke: var(--landing-primary);
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-dasharray: 85 254;
    transform-origin: center;
}

.ring-arc-1 {
    animation: ring-spin 6s linear infinite;
}

.ring-arc-2 {
    animation: ring-spin 5s linear infinite reverse;
    stroke: var(--landing-secondary);
}

.ring-arc-3 {
    animation: ring-spin 7s linear infinite;
    stroke: var(--landing-accent);
}

.ring-arc-4 {
    animation: ring-spin 4.5s linear infinite reverse;
}

@keyframes ring-spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* Node text */
.flow-node-label {
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 0.25rem;
}

.flow-node-desc {
    font-size: 0.82rem;
    color: var(--bs-secondary-color);
    line-height: 1.4;
    padding: 0 0.25rem;
}

/* Connector dots between nodes */
.flow-connector {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 0.25rem 0;
}

@media (min-width: 768px) {
    .flow-connector {
        flex-direction: row;
        padding: 0;
        margin-top: -50px;
    }
}

.connector-dot {
    display: block;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--landing-primary);
    opacity: 0.25;
}

.crypto-flow-section.is-visible .connector-dot {
    animation: dot-pulse 2s ease-in-out infinite;
}

.connector-dot:nth-child(2) {
    animation-delay: 0.3s;
}

.connector-dot:nth-child(3) {
    animation-delay: 0.6s;
}

@keyframes dot-pulse {

    0%,
    100% {
        opacity: 0.15;
        transform: scale(1);
    }

    50% {
        opacity: 0.7;
        transform: scale(1.5);
    }
}

/* ── Tech Divider ────────────────────────────────────────────────────────── */
.tech-divider-label {
    display: inline-block;
    padding: 0.35rem 1.5rem;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--landing-primary);
    border: 1px solid rgba(var(--landing-primary-rgb), 0.2);
    border-radius: 2rem;
    background: rgba(var(--landing-primary-rgb), 0.04);
}

/* ── Tech Grid ───────────────────────────────────────────────────────────── */
.tech-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
}

@media (min-width: 768px) {
    .tech-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Individual tech card */
.tech-card {
    position: relative;
    border-radius: 1.25rem;
    overflow: hidden;
    opacity: 0;
    transform: translateY(24px) scale(0.95);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

/* Staggered entrance */
.crypto-flow-section.is-visible .tech-card[data-tech="1"] {
    transition-delay: 0.15s;
}

.crypto-flow-section.is-visible .tech-card[data-tech="2"] {
    transition-delay: 0.25s;
}

.crypto-flow-section.is-visible .tech-card[data-tech="3"] {
    transition-delay: 0.35s;
}

.crypto-flow-section.is-visible .tech-card[data-tech="4"] {
    transition-delay: 0.45s;
}

.crypto-flow-section.is-visible .tech-card[data-tech="5"] {
    transition-delay: 0.55s;
}

.crypto-flow-section.is-visible .tech-card[data-tech="6"] {
    transition-delay: 0.65s;
}

.crypto-flow-section.is-visible .tech-card[data-tech="7"] {
    transition-delay: 0.75s;
}

.crypto-flow-section.is-visible .tech-card[data-tech="8"] {
    transition-delay: 0.85s;
}

.crypto-flow-section.is-visible .tech-card {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* Hover glow backdrop */
.tech-card-glow {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    opacity: 0;
    transition: opacity 0.35s ease;
    pointer-events: none;
    z-index: 0;
}

.tech-glow-primary {
    background: radial-gradient(ellipse at center, rgba(var(--landing-primary-rgb), 0.10) 0%, transparent 70%);
}

.tech-glow-secondary {
    background: radial-gradient(ellipse at center, rgba(0, 144, 128, 0.10) 0%, transparent 70%);
}

.tech-glow-accent {
    background: radial-gradient(ellipse at center, rgba(85, 184, 48, 0.10) 0%, transparent 70%);
}

[data-bs-theme="dark"] .tech-glow-primary {
    background: radial-gradient(ellipse at center, rgba(var(--landing-primary-rgb), 0.15) 0%, transparent 70%);
}

[data-bs-theme="dark"] .tech-glow-secondary {
    background: radial-gradient(ellipse at center, rgba(46, 196, 182, 0.15) 0%, transparent 70%);
}

[data-bs-theme="dark"] .tech-glow-accent {
    background: radial-gradient(ellipse at center, rgba(126, 217, 87, 0.15) 0%, transparent 70%);
}

.tech-card:hover .tech-card-glow {
    opacity: 1;
}

/* Card inner */
.tech-card-inner {
    position: relative;
    z-index: 1;
    padding: 1.5rem 1rem 1.25rem;
    text-align: center;
    background: var(--landing-card-bg);
    border: 1px solid var(--landing-card-border);
    border-radius: inherit;
    transition: border-color 0.3s ease, transform 0.25s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.tech-card:hover .tech-card-inner {
    transform: translateY(-3px);
    border-color: rgba(var(--landing-primary-rgb), 0.25);
}

/* Card icon with mini ring */
.tech-card-icon {
    position: relative;
    width: 72px;
    height: 72px;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
}

.tech-icon-primary {
    color: var(--landing-primary);
}

.tech-icon-secondary {
    color: var(--landing-secondary);
}

.tech-icon-accent {
    color: var(--landing-accent);
}

.tech-ring-svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.tech-ring-svg .ring-track {
    fill: none;
    stroke: rgba(var(--landing-primary-rgb), 0.06);
    stroke-width: 1.5;
}

.tech-ring-primary {
    fill: none;
    stroke: var(--landing-primary);
    stroke-width: 2;
    stroke-linecap: round;
    stroke-dasharray: 56 170;
    transform-origin: center;
    animation: ring-spin 8s linear infinite;
}

.tech-ring-secondary {
    fill: none;
    stroke: var(--landing-secondary);
    stroke-width: 2;
    stroke-linecap: round;
    stroke-dasharray: 56 170;
    transform-origin: center;
    animation: ring-spin 7s linear infinite reverse;
}

.tech-ring-accent {
    fill: none;
    stroke: var(--landing-accent);
    stroke-width: 2;
    stroke-linecap: round;
    stroke-dasharray: 56 170;
    transform-origin: center;
    animation: ring-spin 9s linear infinite;
}

/* Card text */
.tech-card-label {
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 0.15rem;
}

.tech-card-tag {
    display: inline-block;
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 0.15rem 0.55rem;
    border-radius: 1rem;
    margin-bottom: 0.5rem;
    background: rgba(var(--landing-primary-rgb), 0.07);
    color: var(--landing-primary);
}

.tech-card-desc {
    font-size: 0.78rem;
    color: var(--bs-secondary-color);
    line-height: 1.45;
    flex-grow: 1;
}

/* Mobile compactness */
@media (max-width: 767.98px) {
    .tech-card-inner {
        padding: 1.25rem 0.75rem 1rem;
    }

    .tech-card-icon {
        width: 56px;
        height: 56px;
        font-size: 1.4rem;
        margin-bottom: 0.5rem;
    }

    .tech-card-label {
        font-size: 0.82rem;
    }

    .tech-card-desc {
        font-size: 0.72rem;
    }
}
/* ── Cookie Banner ──────────────────────────────────────────────────────── */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1080;
    background: var(--bs-body-bg);
    border-top: 1px solid var(--bs-border-color);
    box-shadow: 0 -2px 8px rgba(0,0,0,.08);
}
