/* ============================================================
   THEME FRAME & BASE
   ============================================================ */

body.theme-corporate .theme-frame {
    opacity: 1;
    border: none;
    background: transparent;
    z-index: 0 !important; /* Move the frame and its animated texture behind the content */
}

body.theme-corporate .rail-top,
body.theme-corporate .rail-bottom,
body.theme-corporate .rail-left,
body.theme-corporate .rail-right,
body.theme-corporate .floral-bg {
    display: none !important;
}

/*
   BACKGROUND COLOR
   Update this value to change the main background (default is White/Powdery Blue)
*/
body.theme-corporate {
    background-color: var(--color-accent) !important;
    --z-particles-back: 201;
    --z-particles-mid: 202;
    --z-content: 200;
    --z-particles-front: 250;
}

/* Disable the global radial vignette overlay for a cleaner corporate look */
body.theme-corporate .content-wrapper {
    background: none !important;
}

/* ============================================================
   CORPORATE SHAPES — Fluid SVG Layers
   ============================================================ */

/* Hide all background layers by default in this theme */
body.theme-corporate .sway-layer {
    display: none !important;
    position: fixed;
    top: -10vh; left: -10vw;
    width: 120vw;
    height: 120vh;
    pointer-events: none;
    z-index: 2;
    opacity: 0.9;
    transition: opacity 0.5s ease;
    background-size: 100% 100%;
    will-change: transform, opacity;
    --motion-scale: calc(0.1 + 0.9 * var(--frame-intensity, 0.5));
}

/* Base depth layer */
body.theme-corporate .theme-texture {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background:
        radial-gradient(circle at 50% 30%, rgba(255,255,255,0.4) 0%, transparent 70%),
        linear-gradient(113deg,
            rgba(255, 255, 255, 0.4),
            rgba(var(--color-primary-rgb), 0) 27.73%,
            rgba(var(--color-primary-rgb), 0.12) 61.76%,
            rgba(var(--color-primary-rgb), 0.15) 74.37%,
            rgba(var(--color-primary-rgb), 0) 82.35%,
            transparent
        );
    z-index: 0;
    animation: corporate-texture-pulse 12s infinite ease-in-out;
    pointer-events: none;
}

@keyframes corporate-texture-pulse {
    0%, 100% { opacity: calc(0.1 + 0.3 * var(--frame-intensity, 0.5)); }
    50%       { opacity: calc(0.2 + 0.6 * var(--frame-intensity, 0.5)); }
}

/* 1. Dominant Lower Right (Primary Theme Color) */
body.theme-corporate .sway-bottom-right {
    display: block !important;
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1000 1000' preserveAspectRatio='none'%3E%3Cpath d='M-500,2000 C300,900 600,600 1500,200 L1500,2000 Z' fill='black'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1000 1000' preserveAspectRatio='none'%3E%3Cpath d='M-500,2000 C300,900 600,600 1500,200 L1500,2000 Z' fill='black'/%3E%3C/svg%3E");
    mask-size: 100% 100%;
    background: linear-gradient(135deg, var(--color-primary), rgba(var(--color-primary-rgb), 0.8));
    animation: corporate-wander-large calc(47s / var(--gust-speed, 1)) infinite ease-in-out;
}

/* 2. Overlapping White (Front of dominant) */
body.theme-corporate .sway-bottom-left {
    display: block !important;
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1000 1000' preserveAspectRatio='none'%3E%3Cpath d='M-500,2000 C300,1000 600,800 1500,700 L1500,2000 Z' fill='black'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1000 1000' preserveAspectRatio='none'%3E%3Cpath d='M-500,2000 C300,1000 600,800 1500,700 L1500,2000 Z' fill='black'/%3E%3C/svg%3E");
    mask-size: 100% 100%;
    background-color: #ffffff;
    animation: corporate-wander-sub calc(31s / var(--gust-speed, 1)) infinite ease-in-out reverse;
}

/* 3. Accent Shape (Left side) */
body.theme-corporate .sway-left-side {
    display: block !important;
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1000 1000' preserveAspectRatio='none'%3E%3Cpath d='M333,50 C400,200 400,800 333,950 L-500,950 L-500,50 Z' fill='black'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1000 1000' preserveAspectRatio='none'%3E%3Cpath d='M333,50 C400,200 400,800 333,950 L-500,950 L-500,50 Z' fill='black'/%3E%3C/svg%3E");
    mask-size: 100% 100%;
    background: linear-gradient(to bottom, rgba(var(--color-primary-rgb), 0.4), rgba(var(--color-primary-rgb), 0.2));
    animation: corporate-wander-left calc(53s / var(--gust-speed, 1)) infinite ease-in-out;
}

/* 4. Top Curve (Subtle Theme Color) */
body.theme-corporate .sway-top-right {
    display: block !important;
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1000 1000' preserveAspectRatio='none'%3E%3Cpath d='M1500,-200 C700,350 300,500 -500,-200 Z' fill='black'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1000 1000' preserveAspectRatio='none'%3E%3Cpath d='M1500,-200 C700,350 300,500 -500,-200 Z' fill='black'/%3E%3C/svg%3E");
    mask-size: 100% 100%;
    background-color: var(--color-primary);
    opacity: 0.15;
    animation: corporate-wander-top calc(41s / var(--gust-speed, 1)) infinite ease-in-out alternate;
}

/* Animations */
@keyframes corporate-wander-large {
    0%   { transform: translate(0, 0) rotate(0deg) scale(1); }
    25%  { transform: translate(calc(5% * var(--motion-scale)), calc(-2% * var(--motion-scale))) rotate(calc(1deg * var(--motion-scale))) scale(calc(1 + 0.02 * var(--motion-scale))); }
    50%  { transform: translate(calc(-2% * var(--motion-scale)), calc(5% * var(--motion-scale))) rotate(calc(-1deg * var(--motion-scale))) scale(calc(1 + 0.05 * var(--motion-scale))); }
    75%  { transform: translate(calc(-5% * var(--motion-scale)), calc(-5% * var(--motion-scale))) rotate(calc(2deg * var(--motion-scale))) scale(calc(1 + 0.02 * var(--motion-scale))); }
    100% { transform: translate(0, 0) rotate(0deg) scale(1); }
}

@keyframes corporate-wander-sub {
    0%   { transform: translate(0, 0) scale(1); }
    33%  { transform: translate(calc(-4% * var(--motion-scale)), calc(3% * var(--motion-scale))) scale(calc(1 + 0.1 * var(--motion-scale))); }
    66%  { transform: translate(calc(3% * var(--motion-scale)), calc(-4% * var(--motion-scale))) scale(calc(1 - 0.05 * var(--motion-scale))); }
    100% { transform: translate(0, 0) scale(1); }
}

@keyframes corporate-wander-left {
    0%   { transform: translateX(0) skewY(0deg); }
    25%  { transform: translateX(calc(5% * var(--motion-scale))) skewY(calc(2deg * var(--motion-scale))); }
    50%  { transform: translateX(calc(-3% * var(--motion-scale))) skewY(calc(-1deg * var(--motion-scale))); }
    75%  { transform: translateX(calc(8% * var(--motion-scale))) skewY(calc(1deg * var(--motion-scale))); }
    100% { transform: translateX(0) skewY(0deg); }
}

@keyframes corporate-wander-top {
    0%   { transform: translateY(0) rotate(0deg); }
    33%  { transform: translateY(calc(8% * var(--motion-scale))) rotate(calc(2deg * var(--motion-scale))); }
    66%  { transform: translateY(calc(-4% * var(--motion-scale))) rotate(calc(-1deg * var(--motion-scale))); }
    100% { transform: translateY(0) rotate(0deg); }
}

/* ============================================================
   UI COMPONENTS — Frosted Pill Shapes
   ============================================================ */

/* Shared frosted pill base: logo banner and event date */
body.theme-corporate .logo-banner,
body.theme-corporate .event-date {
    background: linear-gradient(to right,
        rgba(255, 255, 255, 0.15) 0%,
        rgba(255, 255, 255, var(--pill-bg-opacity, 0.8)) 15%,
        rgba(255, 255, 255, var(--pill-bg-opacity, 0.8)) 85%,
        rgba(255, 255, 255, 0.15) 100%);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: none !important;
    border-radius: 100px !important;
    color: var(--color-dark-text);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.05);
}

body.theme-corporate .logo-banner {
    --pill-bg-opacity: 0.8;
    padding: 22px 120px;
    position: relative;
    z-index: 100;
    margin-bottom: -3.5rem;
}

body.theme-corporate .event-date {
    --pill-bg-opacity: 0.65;
    padding: 10px 60px;
    font-weight: 600;
}

/* Horizontal Speed Line */
body.theme-corporate .logo-banner::before {
    content: '';
    position: absolute;
    bottom: 15px; left: 15%;
    width: 70%;
    height: 2px;
    background: linear-gradient(to right, transparent, var(--color-primary), transparent);
    border-radius: 100px;
    opacity: 0.8;
    z-index: 1;
}

body.theme-corporate .logo-text-custom {
    font-weight: 700;
    color: var(--color-dark-text);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.8);
}

/* Expand horizontal space for names */
body.theme-corporate .main-content {
    max-width: 1800px;
}

body.theme-corporate .hosts-list {
    max-width: calc(var(--host-max-width) * var(--host-width-base)) !important;
}

/* Relax the narrowing multipliers for Corporate */
body.theme-corporate .hosts-list.layout-justify {
    max-width: calc(var(--host-max-width) * 0.9 * var(--host-width-base)) !important;
}

body.theme-corporate .hosts-list.layout-columns {
    max-width: calc(var(--host-max-width) * 0.85 * var(--host-width-base)) !important;
}

/* Hosts Section */
body.theme-corporate .hosts-container {
    position: relative;
    padding: 20px 40px;
    z-index: 100;
}

/* Equalizing Scrim — Centered behind names to neutralize asymmetrical background shape */
body.theme-corporate .hosts-container::before {
    content: '';
    position: absolute;
    top: 50%; left: 50%;
    width: 120%; height: 120%;
    transform: translate(-50%, -50%);
    background: radial-gradient(ellipse at center,
        rgba(var(--color-accent-rgb), var(--backdrop-opacity)) 33%,
        transparent 66%);
    opacity: var(--backdrop-opacity, 1);
    z-index: -1;
    pointer-events: none;
    filter: blur(15px);
}

body.theme-corporate .hosts-title {
    font-family: var(--font-primary);
    font-weight: 900;
    letter-spacing: 0.5em;
    text-transform: uppercase;
    color: var(--color-text);
    opacity: 1;
    margin-bottom: 30px;
    text-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
}

body.theme-corporate:not(.is-light-bg) .hosts-title {
    color: #ffffff;
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
}

body.theme-corporate .hosts-list span {
    position: relative;
    z-index: 2;
    font-weight: 500;
    color: var(--color-text);
    margin: 6px 12px;
    text-shadow: 0 1px 3px rgba(255, 255, 255, 0.8);
}

body.theme-corporate:not(.is-light-bg) .hosts-list span {
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

/* Footer Section */
body.theme-corporate .event-footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    position: relative;
    z-index: 100;
    margin-top: -1.8rem;
}

body.theme-corporate .event-top-label {
    font-weight: 500;
    font-size: 1.8rem;
    letter-spacing: 0.1em;
    color: var(--color-text);
    opacity: 0.8;
}

body.theme-corporate:not(.is-light-bg) .event-top-label {
    color: #ffffff;
    opacity: 0.9;
}

body.theme-corporate .event-title {
    font-size: 5rem;
    font-weight: 900;
    color: var(--color-text);
    margin: 0 0 1rem 0;
    text-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
}

body.theme-corporate:not(.is-light-bg) .event-title {
    color: #ffffff;
    text-shadow: 0 5px 20px rgba(0, 0, 0, 0.4);
}

body.theme-corporate .event-subtitle {
    font-size: 1.8rem;
    font-weight: 400;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--color-text);
    opacity: 0.8;
    margin-bottom: 0;
}

body.theme-corporate:not(.is-light-bg) .event-subtitle {
    color: #ffffff;
    opacity: 0.9;
}

/* Particle adjustments */
body.theme-corporate .petal {
    border-radius: 50% !important; /* Forces circles */
    filter: blur(1px);
    opacity: 0.6;
}

@media (max-width:1800px) {
    body.theme-corporate .event-footer {
        margin-bottom: 3vh;
    }
    body.theme-corporate .logo-banner{
        margin-top: -2rem;
    }
    body.theme-corporate .hosts-container {
        margin: 6vh 0 -2vh 0;
    }
    body.theme-corporate .hosts-list span {
        font-size: calc(1.1rem * var(--host-text-size) * var(--host-scale-base) * var(--dynamic-scale));
    }
}

@media (min-width: 1801px) {
body.theme-corporate .hosts-container{
    margin-top: 2vh;
    margin-bottom: -3vh;
}
    body.theme-corporate .hosts-list span {
        font-size: calc(1em * var(--host-text-size) * var(--host-scale-base) * var(--dynamic-scale));
    }

    body.theme-corporate .hosts-list {
        margin-left: auto;
        margin-right: auto;

    }


body.theme-corporate.host-hidden .event-footer {
    margin-bottom: unset !important;
    transform: translateY(-4rem) scale(1.8);
}

body.theme-corporate.host-hidden .logo-banner {
    transform: translateY(-0.5rem) scale(2);
}

body.theme-corporate .hosts-list span {
    font-size: calc(1.7em * var(--host-text-size) * var(--host-scale-base) * var(--dynamic-scale));
}
}