/* =============================================
   JAPANESE-INSPIRED THEMES - REDESIGNED
   Cherry Blossom (with landscape), Zen Garden, Ghibli Forest
============================================= */

/* =============================================
   CHERRY BLOSSOM - Japanese Spring with Mountains
============================================= */
html[data-theme="cherry-blossom"],
:root[data-theme="cherry-blossom"] {
    --color-background: #fff8fa;
    --color-surface: #ffffff;
    --color-surface-subtle: #ffe8ed;
    --color-surface-elevated: #ffffff;

    --text-primary: #4a1c2e;
    --text-secondary: #8b5569;
    --text-tertiary: #b08796;

    --border-light: #ffd1dc;
    --border-medium: #ffb3c6;
    --border-dark: #ff9ab5;

    --google-blue: #ff6b9d;
    --google-blue-light: #ff8fb4;
    --google-blue-dark: #e85384;
    --google-blue-subtle: rgba(255, 107, 157, 0.12);

    --google-red: #ff5c8d;
    --google-yellow: #ffc4d6;
    --google-green: #ff9ab5;

    --theme-radius-md: 20px;
    --theme-radius-lg: 24px;
}

html[data-theme="cherry-blossom"] body {
  background: linear-gradient(180deg, #fff8fa 0%, #ffe8ed 100%);
    background-attachment: fixed;
    color: #4a1c2e;
    position: relative;
}

html[data-theme="cherry-blossom"] .glass-card,
html[data-theme="cherry-blossom"] .card {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid var(--border-light);
    border-radius: 20px;
    box-shadow: 0 8px 24px rgba(255, 107, 157, 0.12);
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
    z-index: 1;
}

html[data-theme="cherry-blossom"] .glass-card::after {
 content: '';
    position: absolute;
 top: 0;
    left: 0;
 right: 0;
    height: 3px;
    background: linear-gradient(90deg, #ff6b9d, #ff8fb4, #ffc4d6, #ff8fb4, #ff6b9d);
    background-size: 200% 100%;
    animation: cherryShimmer 3s ease-in-out infinite;
    opacity: 0.6;
}

@keyframes cherryShimmer {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

@keyframes cherrySunGlow {
    0%, 100% { opacity: 0.6; transform: scale(1); }
    50% { opacity: 0.8; transform: scale(1.1); }
}

html[data-theme="cherry-blossom"] .glass-card:hover {
    box-shadow: 0 12px 40px rgba(255, 107, 157, 0.18);
    transform: translateY(-4px) scale(1.01);
}

html[data-theme="cherry-blossom"] h1,
html[data-theme="cherry-blossom"] h2,
html[data-theme="cherry-blossom"] h3 {
    color: #4a1c2e;
}

html[data-theme="cherry-blossom"] .btn,
html[data-theme="cherry-blossom"] .btn-primary,
html[data-theme="cherry-blossom"] button:not(.pill-nav__item):not(.pill-nav__toggle):not(.theme-card) {
    background: linear-gradient(135deg, #ff6b9d 0%, #ff8fb4 100%);
    border: none;
    color: white;
    border-radius: 20px;
    padding: 0.875rem 1.75rem;
    box-shadow: 0 4px 16px rgba(255, 107, 157, 0.3);
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    font-weight: 600;
  position: relative;
    overflow: hidden;
}

html[data-theme="cherry-blossom"] .btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

html[data-theme="cherry-blossom"] .btn:hover::before {
    width: 300px;
    height: 300px;
}

html[data-theme="cherry-blossom"] .btn:hover {
    box-shadow: 0 8px 28px rgba(255, 107, 157, 0.4);
    transform: translateY(-2px) scale(1.02);
}

html[data-theme="cherry-blossom"] .pill-nav {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid var(--border-light);
    border-radius: 30px;
    box-shadow: 0 4px 16px rgba(255, 107, 157, 0.1);
}

html[data-theme="cherry-blossom"] .pill-nav__item {
    border-radius: 20px;
    color: #8b5569;
 transition: all 0.3s ease;
}

html[data-theme="cherry-blossom"] .pill-nav__item:hover {
    background: rgba(255, 107, 157, 0.08);
}

html[data-theme="cherry-blossom"] .pill-nav__item.active {
    background: linear-gradient(135deg, #ff6b9d 0%, #ff8fb4 100%);
  color: white;
    box-shadow: 0 2px 8px rgba(255, 107, 157, 0.3);
}

html[data-theme="cherry-blossom"] input:not([type="checkbox"]):not([type="radio"]),
html[data-theme="cherry-blossom"] select,
html[data-theme="cherry-blossom"] textarea {
    background: white;
    border: 2px solid #ffd1dc;
    border-radius: 20px;
    color: #4a1c2e;
}

html[data-theme="cherry-blossom"] input:focus,
html[data-theme="cherry-blossom"] select:focus,
html[data-theme="cherry-blossom"] textarea:focus {
    border-color: #ff6b9d;
    box-shadow: 0 0 0 4px rgba(255, 107, 157, 0.12);
    outline: none;
}

/* ---------------------------------------------
   CHERRY BLOSSOM - Scene Animations
--------------------------------------------- */
@keyframes cherryMistDrift {
0% { transform: translate3d(-3%,0,0); opacity:0.75; }
100% { transform: translate3d(3%,0,0); opacity:0.95; }
}

@keyframes cherrySunPulse {
0%, 100% { transform: scale(1); opacity: 0.82; }
50% { transform: scale(1.06); opacity: 0.92; }
}

@keyframes cherryTreeSway {
0%, 100% { transform: rotate(-0.8deg); }
50% { transform: rotate(0.8deg); }
}

/* =============================================
   ZEN GARDEN - Refined Minimalist Elegance
============================================= */
html[data-theme="zen-garden"],
:root[data-theme="zen-garden"] {
    --color-background: #f8f7f4;
    --color-surface: #ffffff;
    --color-surface-subtle: #efede8;
    --color-surface-elevated: #ffffff;

    --text-primary: #2a2a28;
    --text-secondary: #5a5a58;
    --text-tertiary: #8a8a88;

    --border-light: rgba(90, 90, 88, 0.12);
    --border-medium: rgba(90, 90, 88, 0.2);
    --border-dark: #7a8a7a;

    --google-blue: #7a8a7a;
    --google-blue-light: #9aaa9a;
 --google-blue-dark: #5a6a5a;
    --google-blue-subtle: rgba(122, 138, 122, 0.08);

    --google-red: #b87a7a;
    --google-yellow: #c4b49a;
    --google-green: #7a8a7a;

    --theme-radius-md: 16px;
    --theme-radius-lg: 20px;
}

html[data-theme="zen-garden"] body {
    background: linear-gradient(135deg, #f8f7f4 0%, #efede8 100%);
    background-attachment: fixed;
    color: #2a2a28;
}

html[data-theme="zen-garden"] .glass-card,
html[data-theme="zen-garden"] .card {
    background: #ffffff;
    border: 1px solid rgba(90, 90, 88, 0.12);
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}

html[data-theme="zen-garden"] .glass-card::before {
    content: '';
    position: absolute;
    left: 0;
  top: 0;
bottom: 0;
    width: 3px;
    background: linear-gradient(180deg, transparent, #7a8a7a, transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
}

html[data-theme="zen-garden"] .glass-card:hover::before {
    opacity: 1;
}

html[data-theme="zen-garden"] .glass-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
    transform: translateY(-2px);
}

html[data-theme="zen-garden"] h1,
html[data-theme="zen-garden"] h2,
html[data-theme="zen-garden"] h3 {
    color: #2a2a28;
    font-weight: 400;
    letter-spacing: 0.02em;
}

html[data-theme="zen-garden"] .btn,
html[data-theme="zen-garden"] .btn-primary,
html[data-theme="zen-garden"] button:not(.pill-nav__item):not(.pill-nav__toggle):not(.theme-card) {
    background: #7a8a7a;
    border: none;
    color: #ffffff;
    border-radius: 12px;
    padding: 0.75rem 2rem;
    box-shadow: 0 2px 8px rgba(122, 138, 122, 0.2);
    transition: all 0.3s ease;
    font-weight: 400;
    letter-spacing: 0.02em;
}

html[data-theme="zen-garden"] .btn:hover {
    background: #6a7a6a;
  box-shadow: 0 4px 12px rgba(122, 138, 122, 0.25);
    transform: translateY(-1px);
}

html[data-theme="zen-garden"] .pill-nav {
    background: #ffffff;
    border: 1px solid rgba(90, 90, 88, 0.12);
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

html[data-theme="zen-garden"] .pill-nav__item {
    color: #5a5a58;
    border-radius: 12px;
    transition: all 0.3s ease;
}

html[data-theme="zen-garden"] .pill-nav__item:hover {
    background: rgba(122, 138, 122, 0.06);
}

html[data-theme="zen-garden"] .pill-nav__item.active {
    background: #7a8a7a;
    color: #ffffff;
}

html[data-theme="zen-garden"] input:not([type="checkbox"]):not([type="radio"]),
html[data-theme="zen-garden"] select,
html[data-theme="zen-garden"] textarea {
    background: #ffffff;
    border: 1px solid rgba(90, 90, 88, 0.2);
  border-radius: 12px;
    color: #2a2a28;
}

html[data-theme="zen-garden"] input:focus,
html[data-theme="zen-garden"] select:focus,
html[data-theme="zen-garden"] textarea:focus {
    border-color: #7a8a7a;
    box-shadow: 0 0 0 3px rgba(122, 138, 122, 0.08);
    outline: none;
}

/* ---------------------------------------------
   ZEN GARDEN - Scene Animations
--------------------------------------------- */
@keyframes zenRakeFlow {
0% { transform: translate3d(0, 0, 0); }
100% { transform: translate3d(0, 36px, 0); }
}

/* =============================================
   GHIBLI FOREST - Enhanced Magical Wonder
============================================= */
html[data-theme="ghibli-forest"],
:root[data-theme="ghibli-forest"] {
 --color-background: #e8f4e8;
    --color-surface: #f5faf5;
    --color-surface-subtle: #dceadc;
    --color-surface-elevated: #ffffff;

    --text-primary: #2d4a2d;
    --text-secondary: #4a6a4a;
    --text-tertiary: #6b8b6b;

    --border-light: rgba(107, 155, 107, 0.2);
    --border-medium: rgba(107, 155, 107, 0.3);
    --border-dark: #6b9b6b;

    --google-blue: #6b9b6b;
    --google-blue-light: #8bbb8b;
    --google-blue-dark: #4b7b4b;
    --google-blue-subtle: rgba(107, 155, 107, 0.12);

    --google-red: #c67a7a;
    --google-yellow: #d4bc8e;
    --google-green: #6b9b6b;

    --theme-radius-md: 16px;
    --theme-radius-lg: 24px;
}

html[data-theme="ghibli-forest"] body {
    background: radial-gradient(ellipse at top, #f0faf0 0%, #e8f4e8 50%, #e0ece0 100%);
    background-attachment: fixed;
    color: #2d4a2d;
}

html[data-theme="ghibli-forest"] .glass-card,
html[data-theme="ghibli-forest"] .card {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(107, 155, 107, 0.25);
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(107, 155, 107, 0.15);
 transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
    z-index: 1;
}

html[data-theme="ghibli-forest"] .glass-card::before {
    content: '';
    position: absolute;
  inset: 0;
    background: radial-gradient(circle at 50% 0%, rgba(107, 155, 107, 0.12), transparent 60%);
    opacity: 0;
    transition: opacity 0.5s ease;
    border-radius: inherit;
    pointer-events: none;
}

html[data-theme="ghibli-forest"] .glass-card:hover::before {
    opacity: 1;
}

html[data-theme="ghibli-forest"] .glass-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
 right: 0;
    height: 4px;
    background: linear-gradient(90deg, 
        rgba(107, 155, 107, 0.3),
        rgba(139, 187, 139, 0.6),
        rgba(107, 155, 107, 0.3));
    background-size: 200% 100%;
    animation: ghibliShimmer 4s ease-in-out infinite;
    border-radius: 20px 20px 0 0;
}

@keyframes ghibliShimmer {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

@keyframes ghibliGlowPulse {
    0%, 100% { opacity: 0.8; }
    50% { opacity: 1; }
}

html[data-theme="ghibli-forest"] .glass-card:hover {
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 16px 48px rgba(107, 155, 107, 0.2);
    transform: translateY(-6px) scale(1.01);
}

html[data-theme="ghibli-forest"] h1,
html[data-theme="ghibli-forest"] h2,
html[data-theme="ghibli-forest"] h3 {
    color: #2d4a2d;
    font-weight: 500;
}

html[data-theme="ghibli-forest"] .btn,
html[data-theme="ghibli-forest"] .btn-primary,
html[data-theme="ghibli-forest"] button:not(.pill-nav__item):not(.pill-nav__toggle):not(.theme-card) {
    background: linear-gradient(135deg, #6b9b6b 0%, #5b8b5b 100%);
    border: none;
    color: #ffffff;
 border-radius: 16px;
  padding: 0.875rem 1.75rem;
 box-shadow: 0 4px 16px rgba(107, 155, 107, 0.3);
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    font-weight: 500;
    position: relative;
    overflow: hidden;
}

html[data-theme="ghibli-forest"] .btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

html[data-theme="ghibli-forest"] .btn:hover::before {
    width: 300px;
    height: 300px;
}

html[data-theme="ghibli-forest"] .btn:hover {
    background: linear-gradient(135deg, #5b8b5b 0%, #4b7b4b 100%);
    box-shadow: 0 8px 24px rgba(107, 155, 107, 0.4);
  transform: translateY(-2px) scale(1.02);
}

html[data-theme="ghibli-forest"] .pill-nav {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(107, 155, 107, 0.25);
    border-radius: 24px;
}

html[data-theme="ghibli-forest"] .pill-nav__item {
    color: #4a6a4a;
    border-radius: 16px;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

html[data-theme="ghibli-forest"] .pill-nav__item:hover {
    background: rgba(107, 155, 107, 0.1);
    transform: translateY(-2px);
}

html[data-theme="ghibli-forest"] .pill-nav__item.active {
    background: linear-gradient(135deg, #6b9b6b, #5b8b5b);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(107, 155, 107, 0.3);
}

html[data-theme="ghibli-forest"] input:not([type="checkbox"]):not([type="radio"]),
html[data-theme="ghibli-forest"] select,
html[data-theme="ghibli-forest"] textarea {
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(107, 155, 107, 0.3);
    border-radius: 16px;
    color: #2d4a2d;
}

html[data-theme="ghibli-forest"] input:focus,
html[data-theme="ghibli-forest"] select:focus,
html[data-theme="ghibli-forest"] textarea:focus {
    border-color: #6b9b6b;
    box-shadow: 0 0 0 4px rgba(107, 155, 107, 0.12);
    outline: none;
}

/* ---------------------------------------------
   GHIBLI FOREST - Scene Animations
--------------------------------------------- */
@keyframes ghibliCloud {
from { transform: translateX(-300px); }
to { transform: translateX(120vw); }
}

.forest-sway-slow {
animation: forestSwayLocal 8s ease-in-out infinite alternate;
transform-origin: bottom center;
}

.forest-sway-med {
animation: forestSwayLocal 6s ease-in-out infinite alternate;
transform-origin: bottom center;
}

@keyframes forestSwayLocal {
0% { transform: rotate(0deg); }
100% { transform: rotate(1.5deg); }
}

@keyframes ghibliBeam {
0%, 100% { transform: translate3d(0, 0, 0) skewX(-2deg); opacity: 0.10; }
50% { transform: translate3d(0, -18px, 0) skewX(2deg); opacity: 0.16; }
}

@keyframes ghibliKodama {
0%, 100% { transform: translate3d(0, 0, 0) scale(0.95); opacity: 0.45; }
50% { transform: translate3d(10px, -10px, 0) scale(1.08); opacity: 0.62; }
}

@keyframes ghibliFirefly {
0%, 100% { opacity: 0.15; transform: scale(0.9); }
50% { opacity: 0.95; transform: scale(1.25); }
}

@keyframes ghibliLeaf {
0% { transform: translate3d(0, -20px, 0) rotate(0deg); opacity: 0; }
10% { opacity: 0.55; }
90% { opacity: 0.55; }
100% { transform: translate3d(60px, 110vh, 0) rotate(540deg); opacity: 0; }
}

/* Zen animations */
@keyframes zenLeafFloat {
    0% {
        transform: translate3d(0, -50px, 0) rotate(0deg);
        opacity: 0;
    }
    10% { opacity: 0.6; }
    90% { opacity: 0.6; }
    100% {
        transform: translate3d(calc(sin(1) * 40px), 110vh, 0) rotate(360deg);
        opacity: 0;
    }
}

@keyframes zenRipplePulse {
    0%, 100% {
        transform: scale(1);
  opacity: 0.3;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.5;
    }
}

@keyframes cherrySunGlow {
    0%, 100% { opacity: 0.7; transform: scale(1); }
    50% { opacity: 0.9; transform: scale(1.05); }
}

/* Ghibli animations */
@keyframes ghibliForestBreath {
    0%, 100% { opacity: 0.8; }
    50% { opacity: 1; }
}

@keyframes ghibliSpiritDance {
    0%, 100% {
        transform: translate3d(0, 0, 0);
        opacity: 0.7;
    }
    25% {
   transform: translate3d(25px, -25px, 0);
        opacity: 0.9;
    }
    50% {
        transform: translate3d(0, -40px, 0);
        opacity: 1;
    }
    75% {
        transform: translate3d(-25px, -25px, 0);
        opacity: 0.9;
    }
}

@keyframes ghibliFireflyTwinkle {
    0%, 100% {
 opacity: 0.4;
transform: scale(0.8);
    }
    50% {
opacity: 1;
        transform: scale(1.3);
    }
}

@keyframes ghibliLeafSwirl {
    0% {
 transform: translate3d(0, -20px, 0) rotate(0deg);
     opacity: 0;
    }
    10% { opacity: 0.8; }
    90% { opacity: 0.8; }
    100% {
        transform: translate3d(
            calc(sin(3) * 70px),
        110vh,
         0
        ) rotate(720deg);
        opacity: 0;
    }
}
