/* === KAWAI VARIABLES === */
:root {
    --pink: #ff9ed8;
    --pink-light: #ffc2e9;
    --pink-dark: #ff7bc8;
    --blue: #87ceeb;
    --blue-light: #b3e0ff;
    --purple: #d9a6ff;
    --yellow: #ffeb3b;
    --yellow-light: #fff9c4;
    --yellow-dark: #ffd54f;
    --green: #a2ff86;
    --green-light: #d4ffc9;
    --orange: #ffb74d;
    --white: #fff9fb;
    --shadow: rgba(255, 105, 180, 0.2);
}

/* === BASE STYLES === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Quicksand', 'Nunito', sans-serif;
    background: linear-gradient(135deg, #ffc2e9 0%, #87ceeb 50%, #d9a6ff 100%);
    color: #5a5a5a;
    min-height: 100vh;
    overflow-x: hidden;
}

/* === ANIME BACKGROUND === */
.anime-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.floating-hearts, .floating-stars, .floating-clouds {
    position: absolute;
    width: 100%;
    height: 100%;
}

.heart, .star, .cloud {
    position: absolute;
    font-size: 1.5rem;
    opacity: 0.6;
    animation: float 6s infinite ease-in-out;
}

.heart:nth-child(1) { top: 10%; left: 5%; animation-delay: 0s; }
.heart:nth-child(2) { top: 20%; left: 80%; animation-delay: 1s; }
.heart:nth-child(3) { top: 60%; left: 10%; animation-delay: 2s; }
.heart:nth-child(4) { top: 80%; left: 70%; animation-delay: 3s; }
.heart:nth-child(5) { top: 40%; left: 90%; animation-delay: 4s; }

.star:nth-child(1) { top: 15%; left: 20%; animation-delay: 0.5s; }
.star:nth-child(2) { top: 70%; left: 30%; animation-delay: 1.5s; }
.star:nth-child(3) { top: 30%; left: 60%; animation-delay: 2.5s; }

.cloud:nth-child(1) { top: 5%; left: 40%; animation-delay: 0.2s; }
.cloud:nth-child(2) { top: 50%; left: 5%; animation-delay: 1.2s; }
.cloud:nth-child(3) { top: 85%; left: 50%; animation-delay: 2.2s; }

@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(5deg); }
}

/* === CONTAINER === */
.kawaii-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
    position: relative;
    z-index: 1;
}

/* === CUTE HEADER === */
.kawaii-header {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 30px;
    margin-bottom: 30px;
    padding: 25px 35px;
    box-shadow: 0 10px 30px var(--shadow);
    border: 3px solid var(--pink);
    position: relative;
    overflow: hidden;
}

.kawaii-header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255,255,255,0.3), transparent);
    transform: rotate(45deg);
    animation: sparkle 3s infinite;
}

@keyframes sparkle {
    0%, 100% { transform: rotate(45deg) translateX(-100%); }
    50% { transform: rotate(45deg) translateX(100%); }
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.mascot {
    flex-shrink: 0;
}

.mascot-face {
    width: 80px;
    height: 80px;
    background: var(--pink);
    border-radius: 50%;
    position: relative;
    border: 3px solid var(--pink-dark);
    animation: bounce 2s infinite ease-in-out;
}

.mascot-eye {
    position: absolute;
    width: 12px;
    height: 12px;
    background: #333;
    border-radius: 50%;
    top: 30px;
    animation: blink 4s infinite;
}

.mascot-eye.left { left: 25px; }
.mascot-eye.right { right: 25px; }

.mascot-mouth {
    position: absolute;
    width: 20px;
    height: 10px;
    border-bottom: 3px solid #333;
    border-radius: 0 0 10px 10px;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

@keyframes blink {
    0%, 45%, 55%, 100% { transform: scaleY(1); }
    48%, 52% { transform: scaleY(0.1); }
}

.header-text h1 {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    font-size: 2.2rem;
    background: linear-gradient(45deg, var(--pink-dark), var(--purple));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-align: center;
}

.header-text p {
    color: var(--pink-dark);
    font-size: 1.1rem;
    text-align: center;
    margin-top: 5px;
}

.header-badges {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.badge.live {
    background: var(--green);
    color: #333;
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    border: 2px solid var(--green-light);
}

.pulse-dot {
    width: 10px;
    height: 10px;
    background: #ff4444;
    border-radius: 50%;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.2); opacity: 0.7; }
}

.current-time {
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    color: var(--purple);
    font-size: 1.1rem;
}

/* === KAWAI GRID === */
.kawaii-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto;
    gap: 25px;
    margin-bottom: 30px;
}

.kawaii-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 25px;
    padding: 25px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 3px solid transparent;
    box-shadow: 0 8px 25px var(--shadow);
}

.kawaii-card:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 15px 35px var(--shadow);
}

.temp-card { border-color: var(--pink); }
.light-card { border-color: var(--yellow); }
.chart-card { 
    grid-column: 1 / -1;
    border-color: var(--purple);
}
.log-card { border-color: var(--orange); }

/* === CARD HEADER === */
.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px dashed var(--pink-light);
}

.card-icon {
    position: relative;
    font-size: 2rem;
    color: var(--pink-dark);
}

.icon-sparkle {
    position: absolute;
    top: -5px;
    right: -5px;
    font-size: 1rem;
    animation: spin 3s infinite linear;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.card-title h2 {
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 1.4rem;
    color: #5a5a5a;
}

.card-title p {
    color: var(--pink-dark);
    font-size: 0.9rem;
}

.status-emoji {
    font-size: 2rem;
    animation: wiggle 2s infinite;
}

@keyframes wiggle {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(5deg); }
    75% { transform: rotate(-5deg); }
}

/* === CUTE DISPLAY === */
.cute-display {
    text-align: center;
    margin-bottom: 25px;
}

.cute-number {
    font-family: 'Nunito', sans-serif;
    font-size: 3.5rem;
    font-weight: 800;
    background: linear-gradient(45deg, var(--pink-dark), var(--purple));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.cute-unit {
    font-size: 1.5rem;
    color: var(--pink-dark);
    margin-left: 5px;
}

.temp-value, .hum-value {
    display: inline-block;
    margin: 0 20px;
}

/* === CUTE INDICATORS === */
.cute-indicators {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin: 25px 0;
}

.indicator {
    background: rgba(255, 255, 255, 0.7);
    padding: 15px;
    border-radius: 20px;
    border: 2px solid var(--pink-light);
}

.indicator-label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    font-weight: 600;
    color: #5a5a5a;
}

.indicator-emoji {
    font-size: 1.2rem;
}

.cute-progress {
    position: relative;
    height: 30px;
}

.progress-track {
    height: 100%;
    background: var(--pink-light);
    border-radius: 15px;
    overflow: hidden;
    position: relative;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--blue), var(--pink));
    border-radius: 15px;
    width: 0%;
    transition: width 0.8s ease;
    position: relative;
}

.progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.progress-marker {
    position: absolute;
    top: -10px;
    left: 0%;
    transform: translateX(-50%);
    font-size: 1.5rem;
    transition: left 0.8s ease;
    animation: bounce 2s infinite ease-in-out;
}

/* === CHARACTER REACTIONS === */
.character-reaction {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
}

.character {
    width: 60px;
    height: 60px;
    background: var(--yellow);
    border-radius: 50%;
    position: relative;
    border: 3px solid var(--orange);
}

.char-face {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.char-eyes {
    display: flex;
    gap: 15px;
    margin-bottom: 5px;
}

.char-eye {
    width: 8px;
    height: 8px;
    background: #333;
    border-radius: 50%;
}

.char-mouth {
    width: 20px;
    height: 8px;
    background: #333;
    border-radius: 0 0 10px 10px;
    margin: 0 auto;
}

.reaction-text {
    background: var(--pink-light);
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: 600;
    color: #5a5a5a;
    border: 2px dashed var(--pink);
}

/* === CUTE LIGHT METER === */
.cute-light-meter {
    margin: 25px 0;
}

.meter-labels {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.meter-label {
    font-weight: 600;
    font-size: 0.9rem;
}

.meter-label.dark { color: var(--purple); }
.meter-label.dim { color: var(--blue); }
.meter-label.bright { color: var(--yellow-dark); }
.meter-label.very-bright { color: #ff6b35; }

.meter-track {
    height: 30px;
    background: linear-gradient(90deg, #8e44ad, #3498db, #f1c40f, #e74c3c);
    border-radius: 15px;
    position: relative;
    border: 2px solid white;
    box-shadow: inset 0 2px 5px rgba(0,0,0,0.1);
}

.meter-fill {
    height: 100%;
    background: rgba(255,255,255,0.3);
    width: 0%;
    transition: width 0.8s ease;
    border-radius: 15px;
}

.meter-indicator {
    position: absolute;
    top: -10px;
    left: 0%;
    transform: translateX(-50%);
    transition: left 0.8s ease;
}

.indicator-arrow {
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-bottom: 15px solid #333;
}

/* === LIGHT LEVEL CHARACTERS === */
.light-level-chars {
    display: flex;
    justify-content: space-around;
    margin-top: 20px;
}

.level-char {
    text-align: center;
    padding: 10px;
    border-radius: 15px;
    transition: all 0.3s ease;
}

.level-char.active {
    background: var(--yellow-light);
    transform: scale(1.1);
    border: 2px solid var(--yellow);
}

.char-emoji {
    font-size: 2rem;
    margin-bottom: 5px;
}

/* === KAWAI BUTTONS === */
.kawaii-btn {
    background: var(--pink);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 25px;
    font-family: 'Quicksand', sans-serif;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 15px var(--shadow);
}

.kawaii-btn:hover {
    background: var(--pink-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px var(--shadow);
}

.kawaii-btn.active {
    background: var(--purple);
    transform: scale(1.05);
}

.kawaii-btn.small {
    padding: 6px 12px;
    font-size: 0.9rem;
}

/* === CHART STYLES === */
.chart-container {
    display: none;
    height: 300px;
}

.chart-container.active {
    display: block;
}

.chart-mascot {
    position: absolute;
    bottom: 20px;
    right: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.mascot-bubble {
    background: var(--pink-light);
    padding: 10px 15px;
    border-radius: 20px;
    position: relative;
    border: 2px solid var(--pink);
}

.mascot-bubble::after {
    content: '';
    position: absolute;
    right: -10px;
    top: 50%;
    transform: translateY(-50%);
    border-left: 10px solid var(--pink);
    border-top: 8px solid transparent;
    border-bottom: 8px solid transparent;
}

.mascot-char {
    font-size: 2rem;
    animation: bounce 2s infinite;
}

/* === CUTE LOG === */
.cute-log-entries {
    height: 150px;
    overflow-y: auto;
    font-family: 'Quicksand', sans-serif;
}

.log-entry {
    padding: 8px 12px;
    margin-bottom: 5px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid var(--pink-light);
}

.log-time {
    color: var(--purple);
    font-weight: 600;
    min-width: 50px;
}

.log-message {
    flex: 1;
    color: #5a5a5a;
}

.log-emoji {
    font-size: 1.2rem;
}

.log-entry.welcome {
    background: var(--pink-light);
    border-color: var(--pink);
}

.writing-cat {
    position: absolute;
    bottom: 15px;
    right: 15px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.cat {
    font-size: 1.5rem;
    animation: typing 1s infinite alternate;
}

.notepad {
    font-size: 1.2rem;
}

@keyframes typing {
    0% { transform: translateY(0); }
    100% { transform: translateY(-5px); }
}

/* === LIGHT CHARACTER === */
.light-character {
    position: absolute;
    bottom: 20px;
    right: 20px;
}

.light-char-face {
    width: 50px;
    height: 50px;
    background: var(--yellow-light);
    border-radius: 50%;
    position: relative;
    border: 2px solid var(--yellow);
}

.light-char-eyes {
    position: absolute;
    top: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.light-char-eye {
    width: 8px;
    height: 8px;
    background: #333;
    border-radius: 50%;
}

.light-char-mouth {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 8px;
    background: #333;
    border-radius: 0 0 10px 10px;
}

/* === KAWAI FOOTER === */
.kawaii-footer {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 20px;
    padding: 20px 30px;
    border: 3px solid var(--pink);
    box-shadow: 0 5px 20px var(--shadow);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-message {
    color: var(--pink-dark);
    font-weight: 600;
}

.update-info {
    color: var(--purple);
    font-weight: 600;
}

.footer-stats {
    color: var(--blue);
}

.stat {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* === RESPONSIVE DESIGN === */
@media (max-width: 1024px) {
    .kawaii-grid {
        grid-template-columns: 1fr;
    }
    
    .header-content {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .cute-number {
        font-size: 2.8rem;
    }
}

@media (max-width: 768px) {
    .kawaii-container {
        padding: 10px;
    }
    
    .kawaii-card {
        padding: 20px;
    }
    
    .temp-value, .hum-value {
        display: block;
        margin: 10px 0;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    
    .character-reaction {
        flex-direction: column;
    }
}