/* Reset */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Base */
body {
    background-color: #e8f5e9;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 16px;
    color: #2e7d32;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Background pattern */
.bg-pattern {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('/static/bg.svg');
    background-size: 150px 150px;
    background-repeat: repeat;
    opacity: 0.4;
    filter: blur(1.5px);
    z-index: 0;
    pointer-events: none;
}

/* App wrapper */
.app-wrapper {
    position: relative;
    z-index: 1;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 24px 16px;
    min-height: 100vh;
}

/* App frame (card) */
.app-frame {
    background: #ffffff;
    border: 4px solid #4caf50;
    border-radius: 20px;
    max-width: 440px;
    width: 100%;
    box-shadow: 0 8px 32px rgba(76, 175, 80, 0.18), 0 2px 8px rgba(0,0,0,0.08);
    overflow: hidden;
}

/* Logo / Header */
.app-logo {
    background: linear-gradient(135deg, #4caf50 0%, #2e7d32 100%);
    padding: 20px 24px 16px;
    text-align: center;
}

.app-logo h1 {
    color: #ffffff;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

/* Page content */
.page-content {
    padding: 28px 24px 24px;
}

.text-center {
    text-align: center;
}

/* Price display */
.price-display {
    background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%);
    border-radius: 14px;
    padding: 20px 16px;
    text-align: center;
    margin-bottom: 20px;
    border: 2px solid #a5d6a7;
}

.price-amount {
    display: block;
    font-size: 3rem;
    font-weight: 800;
    color: #2e7d32;
    line-height: 1.1;
}

.price-label {
    display: block;
    font-size: 1rem;
    color: #558b2f;
    margin-top: 4px;
    font-weight: 500;
}

/* Info boxes */
.info-box {
    background: #f1f8e9;
    border-left: 4px solid #4caf50;
    border-radius: 8px;
    padding: 12px 14px;
    margin-bottom: 14px;
    font-size: 0.93rem;
    color: #33691e;
    line-height: 1.5;
}

.info-box p {
    margin: 0;
}

.info-box.info-note {
    background: #fff8e1;
    border-left-color: #ff9800;
    color: #e65100;
}

/* Forms */
.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    font-weight: 600;
    color: #2e7d32;
    margin-bottom: 6px;
    font-size: 0.95rem;
}

.form-group input[type="text"],
.form-group input[type="password"],
.form-group textarea {
    width: 100%;
    border: 2px solid #a5d6a7;
    border-radius: 10px;
    padding: 10px 12px;
    font-size: 0.97rem;
    font-family: inherit;
    color: #1b5e20;
    background: #f9fbe7;
    transition: border-color 0.2s, box-shadow 0.2s;
    outline: none;
    resize: vertical;
}

.form-group input[type="text"]:focus,
.form-group input[type="password"]:focus,
.form-group textarea:focus {
    border-color: #4caf50;
    box-shadow: 0 0 0 3px rgba(76, 175, 80, 0.18);
    background: #ffffff;
}

/* Buttons */
.btn-container {
    margin-top: 22px;
    text-align: center;
}

.btn {
    display: inline-block;
    background: #4caf50;
    color: #ffffff;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 12px 36px;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(76, 175, 80, 0.35);
    transition: background 0.2s, box-shadow 0.2s, transform 0.1s;
}

.btn:hover {
    background: #43a047;
    box-shadow: 0 6px 18px rgba(76, 175, 80, 0.45);
    transform: translateY(-1px);
}

.btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(76, 175, 80, 0.3);
}

.btn-large {
    font-size: 1.15rem;
    padding: 16px 48px;
}

.btn-available {
    background: #4caf50;
}

.btn-available:hover {
    background: #43a047;
}

.btn-unavailable {
    background: #e53935;
    box-shadow: 0 4px 12px rgba(229, 57, 53, 0.35);
}

.btn-unavailable:hover {
    background: #c62828;
    box-shadow: 0 6px 18px rgba(229, 57, 53, 0.45);
}

/* Waiting page */
.waiting-message {
    margin-bottom: 28px;
}

.waiting-message p {
    font-size: 1.25rem;
    font-weight: 600;
    color: #2e7d32;
    line-height: 1.5;
}

/* Rating page */
.rating-question {
    margin-bottom: 20px;
}

.rating-question p {
    font-size: 1.2rem;
    font-weight: 600;
    color: #2e7d32;
    line-height: 1.5;
}

.stars {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 24px;
}

.star {
    font-size: 2.8rem;
    color: #bdbdbd;
    cursor: pointer;
    transition: color 0.15s, transform 0.1s;
    user-select: none;
    line-height: 1;
}

.star.active,
.star.hover {
    color: #ffc107;
}

.star:hover {
    transform: scale(1.15);
}

/* Thanks page */
.thanks-message {
    padding: 20px 0 28px;
}

.thanks-message p {
    font-size: 1.3rem;
    font-weight: 700;
    color: #2e7d32;
    margin-bottom: 10px;
}

.thanks-sub {
    font-size: 1rem !important;
    font-weight: 400 !important;
    color: #558b2f !important;
}

/* Unavailable */
.unavailable-message {
    padding: 20px 0;
}

.unavailable-message p {
    font-size: 1.1rem;
    color: #c62828;
    font-weight: 500;
    line-height: 1.6;
}

/* Admin styles */
.admin-title {
    font-size: 1.3rem;
    color: #2e7d32;
    margin-bottom: 20px;
    text-align: center;
    font-weight: 700;
}

.error-message {
    background: #ffebee;
    border: 1px solid #ef9a9a;
    border-radius: 8px;
    color: #c62828;
    padding: 10px 14px;
    margin-bottom: 16px;
    font-size: 0.93rem;
}

.status-display {
    text-align: center;
    margin-bottom: 22px;
    font-size: 1rem;
    color: #555;
}

.status-available {
    color: #2e7d32;
}

.status-unavailable {
    color: #c62828;
}

.admin-buttons {
    display: flex;
    gap: 14px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 24px;
}

.admin-logout {
    text-align: center;
}

.btn-link {
    background: none;
    border: none;
    color: #757575;
    font-family: inherit;
    font-size: 0.9rem;
    cursor: pointer;
    text-decoration: underline;
    padding: 4px 8px;
    transition: color 0.2s;
}

.btn-link:hover {
    color: #424242;
}

/* Rejected message */
.rejected-message {
    padding: 20px 0 28px;
}

.rejected-message p {
    font-size: 1.1rem;
    color: #c62828;
    font-weight: 500;
    line-height: 1.6;
}

/* Spinner */
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #c8e6c9;
    border-top-color: #4caf50;
    border-radius: 50%;
    animation: spin 0.9s linear infinite;
    margin: 24px auto 0;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Pending orders list */
.pending-title {
    font-size: 1.05rem;
    color: #2e7d32;
    font-weight: 700;
    margin: 24px 0 12px;
}

.order-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    background: #f1f8e9;
    border: 1px solid #c8e6c9;
    border-radius: 10px;
    padding: 12px 14px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.order-info p {
    font-size: 0.9rem;
    color: #33691e;
    margin-bottom: 2px;
}

.order-actions {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

.btn-sm {
    padding: 8px 18px;
    font-size: 0.85rem;
}

.no-orders {
    text-align: center;
    color: #888;
    font-size: 0.95rem;
    margin: 20px 0;
}

/* Responsive */
@media (max-width: 480px) {
    .app-logo h1 {
        font-size: 1.2rem;
    }

    .page-content {
        padding: 20px 16px 18px;
    }

    .price-amount {
        font-size: 2.3rem;
    }

    .btn {
        padding: 11px 28px;
        font-size: 0.93rem;
    }

    .btn-large {
        font-size: 1.05rem;
        padding: 14px 36px;
    }

    .star {
        font-size: 2.2rem;
        gap: 6px;
    }

    .waiting-message p {
        font-size: 1.05rem;
    }

    .rating-question p {
        font-size: 1.05rem;
    }

    .thanks-message p {
        font-size: 1.1rem;
    }
}
