/* Tea App Complete Styles @version 4.0.0 */

/* 1. CSS VARIABLES */
:root {
    --tea-primary: #4a7c59;
    --tea-secondary: #e6f2ea;
    --tea-accent: #f9a825;
    --tea-dark: #2e4f3b;
    --tea-light: #f8fdf9;
    --tea-text: #333;
    --tea-text-secondary: #666;
    --tea-card-bg: #fff;
    --tea-input-bg: #fff;
    --tea-border: rgb(0 0 0 / 10%);
    --tea-shadow: rgb(0 0 0 / 10%);
    --tea-transition: all 0.3s ease;
    --tea-green: #4a7c59;
    --tea-warm: #fff8e1;
}

/* 2. UTILITY CLASSES */
.hidden { display: none !important; }
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* 3. BASE STYLES */
.tea-app,
.tea-time-app {
    font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background-color: var(--tea-light);
    color: var(--tea-text);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    transition: var(--tea-transition);
}

.tea-app-container {
    max-width: 100%;
    margin: 0;
    padding: 20px;
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 80px);
    position: relative;
    z-index: 1;
    overflow-x: hidden;
}

#tea-app {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

/* 4. HEADER & BANNER */
.tea-app-header {
    background: linear-gradient(135deg, var(--tea-primary) 0%, var(--tea-dark) 100%);
    color: white;
    padding: 16px;
    text-align: center;
    position: relative;
    box-shadow: 0 2px 10px rgb(0 0 0 / 10%);
}

.tea-app-title {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
}

.app-header {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
    padding: 20px;
    background: linear-gradient(135deg, rgb(0 140 69 / 12%) 0%, rgb(0 140 69 / 6%) 100%);
    border-radius: 28px;
    box-shadow: 0 4px 12px rgb(0 0 0 / 5%);
    backdrop-filter: blur(10px);
    border: 1px solid rgb(0 140 69 / 15%);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.app-info { flex: 1; }

.app-info h1 {
    margin: 0 0 8px;
    color: #007a3d;
    font-size: 2.4rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.app-info p {
    margin: 0;
    color: #1a1a1a;
    font-size: 1.2rem;
    font-weight: 500;
    background: rgb(255 255 255 / 90%);
    display: inline-block;
    padding: 4px 10px;
    border-radius: 4px;
}

.tea-app-logo {
    width: 120px;
    height: 120px;
    border-radius: 24px;
    box-shadow: 0 8px 20px rgb(0 140 69 / 25%);
    margin-right: 20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 3px solid var(--tea-primary);
    background-color: var(--tea-primary);
    padding: 8px;
}

.tea-app-logo:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 24px rgb(0 140 69 / 30%);
}

/* Banner */
.tea-banner {
    background: linear-gradient(135deg, var(--tea-primary) 0%, var(--tea-dark) 100%);
    color: white;
    border-radius: 16px;
    padding: 30px;
    margin-bottom: 20px;
    text-align: center;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 6px rgb(0 0 0 / 10%);
}

.tea-banner-content {
    position: relative;
    z-index: 1;
    text-align: center;
    margin: 0 auto;
}

.tea-banner-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 8px;
    text-align: center;
}

.tea-banner-subtitle {
    font-size: 16px;
    opacity: 0.9;
    font-weight: 300;
    text-align: center;
}

/* 5. TAB NAVIGATION */
.tab-navigation {
    display: flex;
    background-color: white;
    border-bottom: 1px solid rgb(74 124 89 / 10%);
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgb(0 0 0 / 5%);
    border-radius: 12px;
    position: relative;
    z-index: 10;
}

.tab-button {
    flex: 1;
    padding: 16px;
    border: none;
    background: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 500;
    color: var(--tea-dark);
    transition: all 0.3s ease;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 56px;
    touch-action: manipulation;
}

.tab-button:hover {
    color: var(--tea-primary);
    background-color: rgb(74 124 89 / 5%);
}

.tab-button.active {
    color: var(--tea-primary);
    font-weight: 600;
}

.tab-button.active::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background-color: var(--tea-primary);
    border-radius: 3px 3px 0 0;
}

.tab-icon { font-size: 1.2rem; }

.tab-content {
    display: none;
    animation: fade-in 0.3s ease;
    position: relative;
    z-index: 5;
}

.tab-content.active { display: block !important; }

/* 6. FORM STYLES */
.tea-form-container {
    position: relative;
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgb(0 0 0 / 5%);
    padding: 30px;
}

.tea-form-section {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.form-group {
    margin-bottom: 20px;
    padding-bottom: 30px;
    border-bottom: 1px solid rgb(74 124 89 / 10%);
}

.form-group:last-of-type {
    border-bottom: none;
    padding-bottom: 0;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--tea-dark);
    font-size: 16px;
}

.form-group h2 {
    font-size: 24px;
    color: var(--tea-text);
    margin-bottom: 20px;
    font-weight: 600;
}

.form-group input[type="text"],
.form-group input[type="number"],
.form-group textarea,
input[type="text"],
textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 16px;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    font-family: inherit;
    min-height: 48px;
    touch-action: manipulation;
    background: var(--tea-input-bg);
    color: var(--tea-text);
}

.form-group input:focus,
.form-group textarea:focus,
input[type="text"]:focus,
textarea:focus {
    outline: none;
    border-color: var(--tea-primary);
    box-shadow: 0 0 0 3px rgb(74 124 89 / 10%);
}

textarea {
    resize: vertical;
    min-height: 100px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.required {
    color: #dc2626;
    font-weight: 400;
}

/* 7. TEA TYPE SELECTION */
.tea-selection-container,
#tea-selection-container {
    background-color: var(--tea-card-bg);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 4px 12px rgb(0 0 0 / 5%);
    max-width: 800px;
    margin: 0 auto 10px;
    position: relative;
    z-index: 20;
}

.tea-selection-container h2,
#tea-selection-container h2 {
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
    text-align: center;
    line-height: 1.3;
    padding: 0 1rem;
    color: var(--tea-dark);
}

.tea-type-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    padding: 1rem;
    max-width: 600px;
    margin: 0 auto;
    justify-content: center;
}

.tea-type-btn {
    padding: 24px 16px;
    background-color: white;
    border: 2px solid #e5e5e5;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 120px;
    touch-action: manipulation;
    box-shadow: 0 2px 6px rgb(0 0 0 / 5%);
}

.tea-type-btn:hover {
    border-color: var(--tea-primary);
    background-color: rgb(74 124 89 / 5%);
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgb(74 124 89 / 15%);
}

.tea-type-btn.active,
.tea-type-btn.selected {
    background-color: var(--tea-primary);
    color: white;
    border-color: var(--tea-primary);
}

/* Tea type color variants */
.tea-type-btn[data-type="green"].active {
    background: linear-gradient(135deg, #4caf50, #45a049);
    border-color: #4caf50;
}
.tea-type-btn[data-type="black"].active {
    background: linear-gradient(135deg, #5d4037, #4e342e);
    border-color: #5d4037;
}
.tea-type-btn[data-type="oolong"].active {
    background: linear-gradient(135deg, #ff9800, #f57c00);
    border-color: #ff9800;
}
.tea-type-btn[data-type="white"].active {
    background: linear-gradient(135deg, #fdd835, #fbc02d);
    border-color: #fdd835;
    color: #333;
}
.tea-type-btn[data-type="herbal"].active {
    background: linear-gradient(135deg, #9c27b0, #7b1fa2);
    border-color: #9c27b0;
}
.tea-type-btn[data-type="pu-erh"].active {
    background: linear-gradient(135deg, #d32f2f, #c62828);
    border-color: #d32f2f;
}

.tea-type-icon {
    font-size: 36px;
    line-height: 1;
}

.tea-type-name {
    font-size: 18px;
    font-weight: 600;
    text-align: center;
    line-height: 1.2;
}

.tea-type-temp {
    font-size: 14px;
    line-height: 1;
    opacity: 0.8;
}

/* 8. RATING SECTION */
.rating-buttons {
    display: flex;
    justify-content: center;
    gap: 12px;
    position: relative;
    z-index: 30;
    flex-wrap: wrap;
    margin-bottom: 25px;
}

.rating-btn {
    flex: 0 0 auto;
    padding: 16px 20px;
    background-color: white;
    border: 2px solid #e5e5e5;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    min-width: 64px;
    min-height: 64px;
    position: relative;
    z-index: 35;
    touch-action: manipulation;
}

.rating-btn:hover {
    border-color: var(--tea-primary);
    background-color: rgb(74 124 89 / 5%);
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgb(74 124 89 / 15%);
}

.rating-btn.active,
.rating-btn.selected {
    background: linear-gradient(135deg, var(--tea-primary), #5d8a60);
    color: white;
    border-color: var(--tea-primary);
    box-shadow: 0 4px 12px rgb(74 124 89 / 20%);
}

.rating-emoji {
    font-size: 32px;
    line-height: 1;
}

.rating-label {
    font-size: 13px;
    font-weight: 600;
    color: #666;
}

.rating-btn.selected .rating-label {
    color: white;
}

/* 9. TIMER STYLES */
.tea-timer-container {
    background-color: var(--tea-card-bg);
    border-radius: 16px;
    padding: 12px;
    box-shadow: 0 4px 12px rgb(0 0 0 / 5%);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.tea-timer-display,
.timer-display {
    position: relative;
    width: 260px;
    height: 260px;
    margin: 32px auto;
    border-radius: 50%;
    background: linear-gradient(135deg, #fff, #f8fcfa);
    box-shadow: 0 10px 30px rgb(0 0 0 / 10%), inset 0 0 0 2px rgb(0 140 69 / 20%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: all 0.3s ease;
}

.tea-timer-text,
#timer-display {
    position: relative;
    z-index: 10;
    font-size: 3rem;
    font-weight: 700;
    color: #007a3d;
    text-shadow: 0 2px 4px rgb(0 0 0 / 10%);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, monospace;
    line-height: 1;
    padding: 1rem;
}

.tea-timer-text.completed {
    color: var(--tea-accent);
    animation: pulse 1.5s infinite;
}

.tea-timer-controls,
.timer-controls {
    display: flex;
    gap: 12px;
    margin-top: 24px;
    justify-content: center;
}

.tea-timer-btn,
.timer-btn {
    padding: 12px 24px;
    border-radius: 50px;
    border: none;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgb(0 0 0 / 10%);
    min-height: 56px;
    min-width: 120px;
    touch-action: manipulation;
}

.tea-timer-btn:hover,
.timer-btn:hover {
    transform: translateY(-2px);
}

.tea-timer-btn:active,
.timer-btn:active {
    transform: scale(0.98);
}

.tea-timer-btn.start,
.timer-btn {
    background: linear-gradient(to bottom right, #00a651, #008c45);
    color: white;
}

.tea-timer-btn.start:hover {
    background: linear-gradient(to bottom right, #009a4b, #007a3d);
    box-shadow: 0 6px 16px rgb(0 140 69 / 30%);
}

.tea-timer-btn.reset {
    background: #f5f5f5;
    color: #555;
    border: 1px solid #e0e0e0;
}

.tea-timer-btn.reset:hover {
    background: #e8e8e8;
}

.timer-btn.hidden { display: none; }

/* Steeping Timer */
.steeping-timer {
    background: linear-gradient(135deg, #f8fdf9, #ffffff);
    border: 2px solid rgb(74 124 89 / 15%);
    border-radius: 16px;
    padding: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

/* 10. WIZARD FLOW */
.tea-wizard-container {
    position: relative;
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
    overflow: hidden;
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgb(0 0 0 / 5%);
    min-height: 600px;
}

.wizard-progress {
    display: flex;
    justify-content: space-between;
    padding: 20px 30px 10px;
    background: linear-gradient(to bottom, #f8fdf9, white);
    border-bottom: 1px solid rgb(74 124 89 / 10%);
    position: relative;
    z-index: 10;
}

.wizard-step-indicator {
    flex: 1;
    position: relative;
    text-align: center;
}

.wizard-step-indicator::before {
    content: '';
    position: absolute;
    top: 15px;
    left: 50%;
    right: -50%;
    height: 2px;
    background: #e0e0e0;
    z-index: -1;
}

.wizard-step-indicator:last-child::before { display: none; }

.wizard-step-indicator.active::before,
.wizard-step-indicator.completed::before {
    background: var(--tea-primary);
}

.step-circle {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #e0e0e0;
    color: #999;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.wizard-step-indicator.active .step-circle {
    background: var(--tea-primary);
    color: white;
    transform: scale(1.1);
}

.wizard-step-indicator.completed .step-circle {
    background: var(--tea-primary);
    color: white;
}

.step-label {
    display: block;
    margin-top: 8px;
    font-size: 12px;
    color: #666;
    font-weight: 500;
}

.wizard-step-indicator.active .step-label {
    color: var(--tea-primary);
    font-weight: 600;
}

/* Wizard Pages */
.wizard-pages {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 500px;
}

.wizard-pages-wrapper {
    display: flex;
    width: 400%;
    height: 100%;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: transform;
}

.wizard-page {
    width: 25%;
    padding: 30px;
    opacity: 0.4;
    transition: opacity 0.4s ease;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.wizard-page.active {
    opacity: 1;
    pointer-events: auto;
}

.wizard-pages-wrapper.step-1 { transform: translateX(0); }
.wizard-pages-wrapper.step-2 { transform: translateX(-25%); }
.wizard-pages-wrapper.step-3 { transform: translateX(-50%); }
.wizard-pages-wrapper.step-4 { transform: translateX(-75%); }

/* Wizard Navigation */
.wizard-navigation {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-top: 32px;
    padding-top: 24px;
}

.wizard-nav {
    position: absolute;
    bottom: 20px;
    left: 30px;
    right: 30px;
    display: flex;
    justify-content: space-between;
    gap: 1rem;
}

.wizard-nav-btn {
    padding: 16px 28px;
    border-radius: 10px;
    font-size: 18px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    min-height: 56px;
    min-width: 140px;
}

.wizard-back-btn {
    background: transparent;
    color: var(--tea-text-secondary);
    border: 1px solid var(--tea-border);
}

.wizard-back-btn:hover {
    background: var(--tea-secondary);
    color: var(--tea-text);
}

.wizard-next-btn {
    background: var(--tea-primary);
    color: white;
    margin-left: auto;
}

.wizard-next-btn:hover:not(:disabled) {
    background: var(--tea-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgb(74 124 89 / 25%);
}

.wizard-next-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* 11. BREW GUIDE */
.brew-guide-section {
    position: relative;
    z-index: 20;
    padding: 1.5rem 1rem;
    max-width: 600px;
    margin: 0 auto;
}

.brew-guide-header {
    text-align: center;
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brew-guide-header h3 {
    font-size: 1.5rem;
    color: var(--tea-dark);
    margin-bottom: 0.5rem;
}

.change-tea-btn {
    background: none;
    border: none;
    color: var(--tea-primary);
    cursor: pointer;
    font-size: 14px;
    text-decoration: underline;
}

.selected-tea-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
    background: #f5faf7;
    padding: 15px;
    border-radius: 12px;
    text-align: center;
}

.selected-tea-type {
    padding: 4px 10px;
    background: var(--tea-primary);
    color: white;
    border-radius: 12px;
    font-size: 0.85rem;
    display: block;
    margin-bottom: 5px;
}

.selected-tea-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--tea-dark);
}

.brew-guide-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
    align-items: start;
}

.brew-parameters {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 30px;
}

.brew-param {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: #f8fdf9;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    min-height: 60px;
}

.param-icon {
    font-size: 1.5rem;
    min-width: 2rem;
    text-align: center;
    flex-shrink: 0;
}

.param-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.param-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #666;
    display: block;
    margin-bottom: 0.25rem;
}

.param-value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--tea-dark);
}

/* 12. ENTRIES & CARDS */
.tea-entries-card,
.tea-stats-card {
    background-color: white;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgb(0 0 0 / 5%);
}

.tea-entries-card h2,
.tea-stats-card h2 {
    margin-top: 0;
    margin-bottom: 20px;
    color: var(--tea-dark);
    font-size: 1.5rem;
}

.entries-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.tea-entry-card {
    background: linear-gradient(135deg, #fff, #f8fffe);
    border-radius: 12px;
    padding: 20px;
    border-left: 4px solid var(--tea-primary);
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgb(0 0 0 / 5%);
}

.tea-entry-card:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 12px rgb(0 0 0 / 10%);
}

/* Entry type color variants */
.tea-entry-card[data-type="green"] { border-left-color: #4caf50; }
.tea-entry-card[data-type="black"] { border-left-color: #5d4037; }
.tea-entry-card[data-type="oolong"] { border-left-color: #ff9800; }
.tea-entry-card[data-type="white"] { border-left-color: #fdd835; }
.tea-entry-card[data-type="herbal"] { border-left-color: #9c27b0; }
.tea-entry-card[data-type="pu-erh"] { border-left-color: #d32f2f; }

.entry-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.tea-name {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--tea-dark);
}

.tea-type-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 12px;
    background: linear-gradient(135deg, var(--tea-primary), #5d8a60);
    color: white;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.entry-details {
    display: flex;
    gap: 20px;
    margin-bottom: 12px;
    font-size: 0.9rem;
    color: #666;
}

.detail {
    display: flex;
    align-items: center;
    gap: 4px;
}

.entry-rating {
    display: flex;
    align-items: center;
    gap: 4px;
    color: #ffd700;
    font-size: 1.1rem;
}

.entry-notes {
    font-style: italic;
    color: #555;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #e5e5e5;
}

.entry-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
}

.entry-date {
    font-size: 0.85rem;
    color: #999;
}

.entry-actions {
    display: flex;
    gap: 8px;
}

.share-btn,
.delete-btn {
    background: none;
    border: 1px solid #ddd;
    color: #666;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.2s ease;
}

.share-btn:hover {
    border-color: var(--tea-primary);
    color: var(--tea-primary);
    background-color: rgb(74 124 89 / 5%);
}

.delete-btn:hover {
    border-color: #dc3545;
    color: #dc3545;
    background-color: rgb(220 53 69 / 5%);
}

/* 13. VENDORS & COLLECTION */
.collection-controls {
    display: flex;
    gap: 1rem;
    margin: 1.5rem 0;
    flex-wrap: wrap;
}

.search-input {
    flex: 1;
    min-width: 200px;
    padding: 0.75rem;
    border: 1px solid var(--tea-border);
    border-radius: 8px;
    background: var(--tea-card-bg);
    color: var(--tea-text);
    font-size: 1rem;
}

.search-input:focus {
    outline: none;
    border-color: var(--tea-primary);
    box-shadow: 0 0 0 3px rgb(74 124 89 / 10%);
}

.filter-select,
.sort-select {
    padding: 0.75rem;
    border: 1px solid var(--tea-border);
    border-radius: 8px;
    background: var(--tea-card-bg);
    color: var(--tea-text);
    font-size: 1rem;
    cursor: pointer;
}

.collection-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    text-align: center;
    padding: 20px;
}

.collection-header h2 {
    margin: 0;
    color: var(--tea-text);
}

.add-tea-btn {
    padding: 10px 20px;
    background: linear-gradient(135deg, var(--tea-primary), #5d8a60);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s ease;
}

.add-tea-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgb(74 124 89 / 30%);
}

/* Vendor Grid */
.vendors-grid,
.shops-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.vendor-card,
.shop-card {
    background: var(--tea-secondary);
    border-radius: 12px;
    padding: 1.5rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.vendor-card:hover,
.shop-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgb(0 0 0 / 10%);
}

.vendor-header,
.shop-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 1rem;
}

.vendor-header h3,
.shop-header h3 {
    margin: 0;
    color: var(--tea-text);
    font-size: 1.25rem;
}

.vendor-stats,
.shop-stats {
    display: flex;
    gap: 1.5rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--tea-border);
    color: var(--tea-text-secondary);
    font-size: 0.875rem;
}

/* Tea Collection */
.tea-collection {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.tea-collection-grid {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.tea-card {
    background: var(--tea-secondary);
    border-radius: 12px;
    padding: 1.25rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.tea-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgb(0 0 0 / 10%);
}

.tea-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 0.75rem;
}

.tea-header h3 {
    margin: 0;
    color: var(--tea-text);
    font-size: 1.125rem;
}

.tea-type {
    color: var(--tea-text-secondary);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

/* 14. STATISTICS & INSIGHTS */
.stats-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.stat-card.enhanced {
    background: linear-gradient(135deg, #f5faf7, #e8f5e9);
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    transition: transform 0.2s ease;
}

.stat-card.enhanced:hover {
    transform: translateY(-2px);
}

.stat-icon {
    font-size: 28px;
    display: block;
    margin-bottom: 8px;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--tea-primary);
    display: block;
    margin-bottom: 4px;
}

.stat-label {
    font-size: 16px;
    color: #666;
    display: block;
    font-weight: 500;
}

/* Insights */
.insights-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.insights-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.insight-card {
    background-color: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 8px rgb(74 124 89 / 10%);
    text-align: center;
    transition: transform 0.2s ease;
}

.insight-card:hover {
    transform: translateY(-2px);
}

.insight-icon {
    font-size: 2.5rem;
    margin-bottom: 12px;
}

.insight-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--tea-primary);
    margin-bottom: 4px;
    display: block;
}

.insight-label {
    font-size: 0.9rem;
    color: #666;
    display: block;
}

/* 15. MODALS */
.modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgb(0 0 0 / 50%);
    backdrop-filter: blur(4px);
}

.modal-content {
    position: relative;
    background: var(--tea-card-bg);
    border-radius: 16px;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 25px -5px rgb(0 0 0 / 10%);
    padding: 32px;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 20px;
    margin-bottom: 24px;
    border-bottom: 2px solid #f0f0f0;
}

.modal-header h2 {
    margin: 0;
    color: var(--tea-text);
    font-size: 1.6rem;
    font-weight: 700;
}

.modal-close {
    background: none;
    border: none;
    color: var(--tea-text-secondary);
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-body {
    margin-bottom: 28px;
}

.modal-actions,
.modal-footer {
    display: flex;
    gap: 16px;
    justify-content: flex-end;
    padding-top: 20px;
    border-top: 2px solid #f0f0f0;
}

/* 16. NOTIFICATIONS */
.notification,
.toast-notification {
    position: fixed;
    top: 80px;
    right: 20px;
    padding: 20px 24px;
    border-radius: 12px;
    background-color: var(--tea-primary);
    color: white;
    box-shadow: 0 4px 12px rgb(0 0 0 / 20%);
    transform: translateX(400px);
    transition: transform 0.3s ease;
    z-index: 1001;
    min-height: 60px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 16px;
}

.notification.show,
.toast-notification.show {
    transform: translateX(0);
}

.notification.success { background-color: #059669; }
.notification.error { background-color: #dc2626; }
.notification.info { background-color: #3b82f6; }

/* 17. EMPTY STATES */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--tea-text-secondary);
}

.empty-icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.empty-state p { margin: 8px 0; }

.no-previous-teas {
    text-align: center;
    padding: 3rem;
    color: var(--tea-text-secondary);
}

.no-previous-teas-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* 18. ONBOARDING */
.onboarding-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 60px);
    padding: 20px;
}

.onboarding-content {
    max-width: 600px;
    text-align: center;
    background: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgb(0 0 0 / 10%);
}

.onboarding-icon {
    font-size: 80px;
    margin-bottom: 20px;
    animation: tea-steam 4s ease-in-out infinite;
}

.onboarding-content h1 {
    font-size: 32px;
    color: var(--tea-primary);
    margin-bottom: 10px;
}

.onboarding-tagline {
    font-size: 18px;
    color: #666;
    margin-bottom: 30px;
}

.benefits-list {
    text-align: left;
    margin: 30px 0;
}

.benefit-item {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    padding: 15px;
    background: #f5faf7;
    border-radius: 12px;
}

.benefit-icon {
    font-size: 30px;
    flex-shrink: 0;
}

.benefit-item h3 {
    font-size: 16px;
    margin-bottom: 5px;
    color: #333;
}

.benefit-item p {
    font-size: 14px;
    color: #666;
    margin: 0;
}

.privacy-note {
    font-size: 12px;
    color: #999;
    margin-top: 15px;
}

/* 19. ANIMATIONS */
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

@keyframes steam {
    0% {
        transform: translateX(-50%) translateY(0) scale(1);
        opacity: 0.7;
    }
    100% {
        transform: translateX(-50%) translateY(-20px) scale(1.5);
        opacity: 0;
    }
}

@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes tea-steam {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25% { transform: translateY(-5px) rotate(-5deg); }
    75% { transform: translateY(-5px) rotate(5deg); }
}

@keyframes slide-in {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* 20. RESPONSIVE - TABLET */
@media (min-width: 960px) {
    .tea-app-container {
        padding: 24px 40px;
    }

    .tea-banner {
        max-width: 900px;
        margin: 0 auto 20px;
    }

    .tab-navigation {
        justify-content: center;
        max-width: 600px;
        margin: 0 auto 20px;
    }

    .tab-button {
        max-width: 300px;
    }

    .tea-form-container {
        padding: 32px;
    }

    .insights-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (min-width: 1400px) {
    .tea-app-container {
        padding: 32px 60px;
    }

    .tab-navigation {
        max-width: 800px;
    }

    .tea-form-container {
        padding: 40px;
    }
}

/* 21. RESPONSIVE - MOBILE */
@media (max-width: 768px) {
    .tea-app-container {
        padding: 0;
        padding-bottom: 2rem;
    }

    .tea-banner {
        padding: 1.5rem 1rem;
        text-align: center;
    }

    .tea-banner-title {
        font-size: 1.5rem;
    }

    .tea-banner-subtitle {
        font-size: 0.875rem;
        margin-top: 0.5rem;
    }

    .tab-navigation {
        display: flex;
        width: 100%;
        border-bottom: 1px solid var(--tea-border);
        background: var(--tea-card-bg);
        position: sticky;
        top: 0;
        z-index: 100;
    }

    .tab-button {
        flex: 1;
        min-height: 56px;
        padding: 0.75rem;
        font-size: 0.875rem;
        flex-direction: column;
        gap: 0.25rem;
    }

    .tab-icon {
        font-size: 1.25rem;
    }

    .tea-selection-container,
    #tea-selection-container {
        padding: 1rem;
    }

    .tea-selection-container h2,
    #tea-selection-container h2 {
        font-size: 1.5rem;
        margin-bottom: 1.5rem;
    }

    .tea-type-grid {
        grid-template-columns: repeat(2, minmax(150px, 1fr));
        gap: 1rem;
        padding: 1rem;
    }

    .tea-type-btn {
        min-height: 120px;
        padding: 1rem 0.75rem;
    }

    .tea-type-icon {
        font-size: 2rem;
    }

    .tea-type-name {
        font-size: 0.875rem;
    }

    .tea-type-temp {
        font-size: 0.75rem;
    }

    .rating-buttons {
        justify-content: space-around;
        gap: 0.5rem;
        padding: 0.5rem;
    }

    .rating-btn {
        min-width: 56px;
        min-height: 56px;
        padding: 0.5rem;
    }

    .rating-emoji {
        font-size: 1.75rem;
    }

    .rating-label {
        display: none;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .app-header {
        flex-direction: column;
        text-align: center;
        padding: 16px;
    }

    .tea-app-logo {
        margin-right: 0;
        margin-bottom: 16px;
    }

    .brew-guide-section {
        padding: 1rem;
    }

    .brew-guide-content {
        grid-template-columns: 1fr;
    }

    .timer-display {
        font-size: 36px;
    }

    .steeping-timer {
        padding: 20px;
    }

    .collection-controls {
        flex-direction: column;
    }

    .vendors-grid,
    .shops-grid,
    .tea-collection {
        grid-template-columns: 1fr;
    }

    .wizard-navigation {
        flex-direction: column-reverse;
    }

    .wizard-next-btn {
        width: 100%;
        margin-left: 0;
    }

    .wizard-back-btn {
        width: 100%;
    }

    .onboarding-content {
        padding: 30px 20px;
    }

    .onboarding-icon {
        font-size: 60px;
    }

    .onboarding-content h1 {
        font-size: 28px;
    }
}

/* 22. RESPONSIVE - SMALL MOBILE */
@media (max-width: 480px) {
    .tea-app-container {
        width: 100%;
        max-width: 100vw;
        overflow-x: hidden;
    }

    .tea-type-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
        padding: 0 1rem;
    }

    .tea-type-btn {
        min-height: 140px;
        padding: 1.5rem 1rem;
    }

    .tea-banner-title {
        font-size: 1.75rem;
    }

    .rating-buttons {
        gap: 0.75rem;
        padding: 0 0.5rem;
    }

    .rating-btn {
        width: 56px;
        height: 56px;
        padding: 0;
    }

    .rating-emoji {
        font-size: 1.5rem;
    }

    .toast-notification {
        bottom: 80px;
        left: 1rem;
        right: 1rem;
        max-width: calc(100% - 2rem);
        transform: translateX(0) translateY(100px);
        margin: 0;
    }

    .toast-notification.show {
        transform: translateX(0) translateY(0);
    }

    .modal-content {
        width: 95%;
        padding: 24px 16px;
    }

    .wizard-nav-btn {
        width: 100%;
        min-height: 60px;
    }
}

/* 23. RESPONSIVE - HALFTOP (960x987) */
@media (min-width: 960px) and (min-height: 900px) and (max-height: 1100px) {
    .tea-app-container {
        max-width: 100%;
        padding: 20px 40px;
        min-height: calc(100vh - 80px);
        display: flex;
        flex-direction: column;
        align-items: stretch;
    }

    #tea-app {
        width: 100%;
        max-width: 1200px;
        margin: 0 auto;
        display: flex;
        flex-direction: column;
        align-items: stretch;
    }

    .tea-banner {
        padding: 25px;
        margin: 0 auto 15px;
        max-width: 900px;
        width: 100%;
        text-align: center;
    }

    .tea-banner-title {
        font-size: 28px;
    }

    .tea-banner-subtitle {
        font-size: 15px;
    }

    .tab-navigation {
        margin: 0 auto 20px;
        max-width: 700px;
    }

    .tea-selection-container,
    #tea-selection-container {
        max-width: 850px;
        margin: 0 auto;
        padding: 30px;
    }

    .tea-type-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.25rem;
        max-width: 600px;
        margin: 0 auto 2rem;
    }

    .tea-type-btn {
        padding: 1.5rem 1rem;
        min-height: 140px;
    }

    .tea-type-btn:hover {
        transform: translateY(-4px);
        box-shadow: 0 8px 20px rgb(74 124 89 / 15%);
    }

    .onboarding-container {
        min-height: calc(100vh - 100px);
    }

    .onboarding-content {
        max-width: 800px;
        padding: 80px 80px 60px;
    }

    .onboarding-icon {
        font-size: 5rem;
        margin-bottom: 2.5rem;
    }

    .onboarding-content h1 {
        font-size: 3rem;
        margin-bottom: 1.5rem;
    }

    .onboarding-tagline {
        font-size: 1.5rem;
        margin-bottom: 4rem;
    }
}

/* 24. RESPONSIVE - DESKTOP */
@media (min-width: 1024px) {
    .tea-type-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
        max-width: 900px;
        margin: 0 auto;
    }

    .tea-type-btn {
        min-height: 140px;
        padding: 28px 20px;
    }

    .timer-display {
        width: 320px;
        height: 320px;
    }

    .tea-timer-text,
    #timer-display {
        font-size: 4rem;
    }
}

@media (min-width: 1920px) {
    .tea-app-container {
        padding: 40px 80px;
    }
}

/* Hover states for desktop */
@media (hover: hover) {
    button:hover:not(:disabled),
    .btn:hover:not(:disabled) {
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgb(0 0 0 / 15%);
    }

    .tea-type-btn:hover,
    .rating-btn:hover {
        border-color: var(--tea-primary);
        background: var(--tea-secondary);
    }

    .tea-entry-card:hover,
    .tea-card:hover,
    .vendor-card:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 20px rgb(0 0 0 / 12%);
    }
}

/* 25. THEME FIXES */
.real-mode .toast-notification {
    background: #2d3748;
    color: #f7fafc;
}

.real-mode .brew-param {
    background: rgb(255 255 255 / 8%);
}

.real-mode .tab-button.active {
    color: var(--tea-primary);
}

.real-mode .benefit-item {
    background: rgb(255 255 255 / 5%);
}

.real-mode .tea-type-btn {
    background: var(--bg-secondary);
    border-color: var(--border-color);
}

.real-mode .previous-teas-section {
    background: rgb(255 255 255 / 5%);
}

.real-mode .insight-card {
    background-color: var(--bg-secondary);
}

.real-mode .tea-card,
.real-mode .vendor-card,
.real-mode .shop-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
}

/* 26. ACCESSIBILITY */
/* Focus States */
button:focus,
button:focus-visible,
.tea-type-btn:focus,
.rating-btn:focus,
input:focus,
textarea:focus,
select:focus {
    outline: 3px solid var(--tea-primary);
    outline-offset: 2px;
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .tea-entry-card,
    .tea-card {
        border: 2px solid var(--tea-primary);
    }

    button,
    .btn {
        border: 2px solid currentcolor;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Prevent Text Selection on Buttons */
button,
.tea-type-btn,
.rating-btn,
.tab-button,
.wizard-nav-btn {
    user-select: none;
}

/* Tap Highlight */
* {
    -webkit-tap-highlight-color: transparent;
}

/* Smooth Scrolling */
.tea-app-page {
    scroll-behavior: smooth;
}

/* Button Readability */
.btn,
button {
    line-height: 1.4;
    letter-spacing: 0.3px;
}

/* Primary Button */
.btn-primary {
    background-color: var(--tea-primary);
    color: white;
    font-size: 18px;
    padding: 15px 40px;
    margin-top: 20px;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
}

.btn-primary:hover {
    background-color: var(--tea-dark);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgb(0 0 0 / 20%);
}

/* Submit Button */
.submit-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, var(--tea-primary), #5d8a60);
    color: white;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgb(74 124 89 / 25%);
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgb(74 124 89 / 35%);
}

.submit-btn:disabled {
    background: #cccccc;
    cursor: not-allowed;
    opacity: 0.6;
}

/* Quick Steep Button */
.quick-steep-btn,
#repeat-last-tea {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, var(--tea-primary), #5d8a60);
    color: white;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgb(74 124 89 / 20%);
    min-height: 56px;
}

.quick-steep-btn:hover,
#repeat-last-tea:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgb(74 124 89 / 30%);
}

.quick-steep-icon { font-size: 24px; }

.quick-steep-text {
    flex: 1;
    text-align: left;
}

.quick-steep-text strong {
    display: block;
    font-size: 1rem;
    margin-bottom: 4px;
}

.quick-steep-text small {
    font-size: 0.85rem;
    opacity: 0.9;
}

/* Log Button */
.log-tea-btn {
    padding: 16px 40px;
    font-size: 18px;
    font-weight: 600;
    background: var(--tea-primary);
    color: white;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.log-tea-btn:hover:not(:disabled) {
    background: var(--tea-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgb(74 124 89 / 25%);
}

.log-tea-btn:disabled {
    background: #cccccc;
    cursor: not-allowed;
    opacity: 0.6;
}

.btn-icon { font-size: 20px; }

/* Back Button Container */
.back-button-container {
    position: relative;
    margin: 2rem auto;
    width: 100%;
    max-width: 600px;
    text-align: center;
    padding: 1rem;
    background: transparent;
}

.back-button-container a {
    display: inline-block;
    margin: 0.5rem;
}

/* Previous Teas */
.previous-teas-section {
    margin: 20px 0;
    padding: 1rem;
    background: #f8fdf9;
    border-radius: 12px;
}

.previous-teas-section.hidden { display: none; }

.previous-teas-label {
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--tea-primary);
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.previous-teas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
    margin-bottom: 15px;
    max-height: 200px;
    overflow-y: auto;
}

.previous-tea-card {
    padding: 0.75rem;
    background: white;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.previous-tea-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgb(0 0 0 / 10%);
    border-color: var(--tea-primary);
}

.previous-tea-card.selected {
    border-color: var(--tea-primary);
    background: linear-gradient(to bottom, #f8fdf9, white);
}

.tea-card-info { flex: 1; }

.tea-card-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--tea-dark);
    margin-bottom: 0.25rem;
}

.tea-card-details {
    font-size: 0.7rem;
    color: #666;
    display: flex;
    gap: 1rem;
}

.tea-card-rating { font-size: 1.25rem; }

/* Manual Tea Input */
.manual-tea-input {
    width: 100%;
    max-width: 500px;
    padding: 1rem;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: var(--tea-card-bg);
    color: var(--tea-text);
}

.manual-tea-input:focus {
    outline: none;
    border-color: var(--tea-primary);
    box-shadow: 0 0 0 3px rgb(74 124 89 / 10%);
}

/* Notes Section */
.notes-section {
    width: 100%;
    max-width: 600px;
    margin: 0 auto 2rem;
}

.notes-section label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--tea-dark);
    font-size: 14px;
}

.notes-section textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    resize: vertical;
    min-height: 100px;
}

/* Form Actions */
.form-actions {
    text-align: center;
    padding-top: 20px;
}

/* Quick Rating Section */
.quick-rating-section {
    position: relative;
    z-index: 25;
    margin-top: 2rem;
    padding-top: 1.5rem;
}

.quick-rating-section h3 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
}

/* Type Badge */
.selected-type-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: linear-gradient(to bottom, #f8fdf9, white);
    border: 1px solid rgb(74 124 89 / 20%);
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    color: var(--tea-primary);
    margin-bottom: 15px;
}

.selected-type-badge.hidden { display: none; }

.selected-type-badge .type-icon { font-size: 18px; }

/* Divider */
.divider-or {
    text-align: center;
    color: #999;
    font-size: 0.85rem;
    margin: 1rem 0;
    position: relative;
}

.divider-or::before,
.divider-or::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 40%;
    height: 1px;
    background: #e0e0e0;
}

.divider-or::before { left: 0; }
.divider-or::after { right: 0; }

/* 27. COLLAPSIBLE SECTIONS */
.collapsible-section {
    margin-bottom: 1rem;
}

.collapsible-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.75rem 1rem;
    background: var(--tea-secondary);
    border: 1px solid var(--tea-border);
    border-radius: 8px;
    color: var(--tea-primary);
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--tea-transition);
}

.collapsible-toggle:hover {
    background: linear-gradient(to bottom, var(--tea-secondary), #d9ebe0);
}

.collapsible-toggle:focus {
    outline: 2px solid var(--tea-primary);
    outline-offset: 2px;
}

.collapsible-toggle .toggle-icon {
    font-size: 0.75rem;
    transition: transform 0.2s ease;
}

/* Inline variant for smaller toggles like "Add notes" */
.collapsible-toggle--inline {
    width: auto;
    padding: 0.5rem 0.75rem;
    background: transparent;
    border: 1px dashed var(--tea-border);
    font-size: 0.875rem;
    color: var(--tea-text-secondary);
}

.collapsible-toggle--inline:hover {
    background: var(--tea-secondary);
    border-style: solid;
    color: var(--tea-primary);
}

.collapsible-toggle--inline .toggle-icon {
    font-size: 1rem;
    font-weight: 300;
}

.collapsible-content {
    overflow: hidden;
    transition: max-height 0.3s ease, opacity 0.3s ease, padding 0.3s ease;
    max-height: 500px;
    opacity: 1;
    padding-top: 1rem;
}

.collapsible-content.collapsed {
    max-height: 0;
    opacity: 0;
    padding-top: 0;
    pointer-events: none;
}

/* Notes textarea inside collapsible */
.collapsible-content textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--tea-border);
    border-radius: 8px;
    font-size: 0.95rem;
    resize: vertical;
    min-height: 80px;
}

.collapsible-content textarea:focus {
    outline: none;
    border-color: var(--tea-primary);
    box-shadow: 0 0 0 3px rgb(74 124 89 / 15%);
}

/* 28. FLOATING TIMER */
.floating-timer-btn {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--tea-primary);
    border: none;
    box-shadow: 0 4px 12px rgb(0 0 0 / 25%);
    cursor: pointer;
    z-index: 100;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.floating-timer-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 16px rgb(0 0 0 / 30%);
}

.floating-timer-btn:active {
    transform: scale(0.95);
}

.floating-timer-btn.active {
    background: var(--tea-dark);
}

.floating-timer-btn .timer-icon {
    font-size: 1.5rem;
}

/* Timer Panel */
.timer-panel {
    position: fixed;
    bottom: 96px;
    right: 24px;
    width: 280px;
    background: var(--tea-card-bg);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgb(0 0 0 / 20%);
    z-index: 99;
    overflow: hidden;
    transform: translateY(0);
    opacity: 1;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.timer-panel.hidden {
    transform: translateY(20px);
    opacity: 0;
    pointer-events: none;
}

.timer-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    background: var(--tea-primary);
    color: white;
}

.timer-panel-header h3 {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
}

.timer-panel-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.timer-panel-close:hover {
    opacity: 1;
}

.timer-panel-content {
    padding: 1.5rem;
    text-align: center;
}

.timer-display-large {
    font-size: 3rem;
    font-weight: 700;
    color: var(--tea-primary);
    font-variant-numeric: tabular-nums;
    margin-bottom: 1rem;
}

.timer-panel .timer-controls {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    margin-bottom: 1rem;
}

.timer-panel .timer-btn {
    padding: 0.625rem 1.5rem;
    border: 1px solid var(--tea-border);
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--tea-transition);
    background: white;
    color: var(--tea-text);
}

.timer-panel .timer-btn--primary {
    background: var(--tea-primary);
    border-color: var(--tea-primary);
    color: white;
}

.timer-panel .timer-btn--primary:hover {
    background: var(--tea-dark);
    border-color: var(--tea-dark);
}

.timer-panel .timer-btn:not(.timer-btn--primary):hover {
    background: var(--tea-secondary);
}

.timer-presets {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.timer-preset {
    padding: 0.375rem 0.75rem;
    background: var(--tea-secondary);
    border: 1px solid transparent;
    border-radius: 20px;
    font-size: 0.8rem;
    color: var(--tea-text-secondary);
    cursor: pointer;
    transition: var(--tea-transition);
}

.timer-preset:hover {
    background: var(--tea-primary);
    color: white;
}

.timer-preset.selected {
    background: var(--tea-primary);
    color: white;
    border-color: var(--tea-dark);
}

/* Mobile adjustments for floating timer */
@media (max-width: 480px) {
    .floating-timer-btn {
        bottom: 16px;
        right: 16px;
        width: 48px;
        height: 48px;
    }

    .floating-timer-btn .timer-icon {
        font-size: 1.25rem;
    }

    .timer-panel {
        bottom: 80px;
        right: 16px;
        left: 16px;
        width: auto;
    }

    .timer-display-large {
        font-size: 2.5rem;
    }
}
