/* Global Styles */
:root {
    --primary-color: #ff6b35;
    /* Appetizing Orange */
    --secondary-color: #2c3e50;
    /* Dark Blue-Gray */
    --accent-color: #27ae60;
    /* Fresh Green */
    --background-graident: linear-gradient(135deg, #1a1a1a, #2d3436);
    --card-bg: rgba(255, 255, 255, 0.95);
    --glass-bg: rgba(255, 255, 255, 0.1);
    --text-dark: #2d3436;
    --text-light: #f5f6fa;
    --border-radius: 16px;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Outfit', sans-serif;
}

body {
    background: var(--background-graident);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    color: var(--text-dark);
}

.background-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('https://images.unsplash.com/photo-1574126154517-d1e0d89e7344?ixlib=rb-1.2.1&auto=format&fit=crop&w=1920&q=80');
    background-size: cover;
    background-position: center;
    opacity: 0.15;
    z-index: -1;
}

.container {
    background: var(--card-bg);
    width: 100%;
    max-width: 500px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    backdrop-filter: blur(10px);
    animation: slideIn 0.5s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

header {
    background: var(--primary-color);
    color: white;
    padding: 30px 20px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

header::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 0;
    width: 100%;
    height: 40px;
    background: var(--card-bg);
    border-radius: 50% 50% 0 0;
}

header h1 {
    font-size: 2rem;
    margin-bottom: 5px;
    font-weight: 700;
}

header p {
    font-weight: 300;
    opacity: 0.9;
}

main {
    padding: 20px;
    padding-top: 10px;
}

/* Menu Item Card */
.menu-item-card {
    text-align: center;
    margin-bottom: 30px;
}

.food-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: var(--border-radius);
    margin-bottom: 15px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.item-details h2 {
    color: var(--secondary-color);
    margin-bottom: 5px;
}

.price {
    color: var(--primary-color);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.price .unit {
    font-size: 1rem;
    color: #7f8c8d;
    font-weight: 400;
}

.description {
    color: #636e72;
    margin-bottom: 20px;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Controls */
.control-group {
    margin-bottom: 20px;
    text-align: left;
}

.control-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--secondary-color);
}

.quantity-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f1f2f6;
    border-radius: 30px;
    padding: 5px;
    width: fit-content;
    margin: 0 auto;
}

.qty-btn {
    background: white;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    color: var(--secondary-color);
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qty-btn:hover {
    background: var(--primary-color);
    color: white;
}

.qty-btn:active {
    transform: scale(0.9);
}

#quantity {
    background: transparent;
    border: none;
    width: 50px;
    text-align: center;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--secondary-color);
}

/* Custom Checkbox */
.checkbox-group {
    display: grid;
    gap: 10px;
}

.checkbox-container {
    display: flex;
    align-items: center;
    position: relative;
    padding: 10px 15px;
    background: white;
    border: 2px solid #f1f2f6;
    border-radius: 12px;
    cursor: pointer;
    transition: 0.2s;
    font-size: 0.95rem;
}

.checkbox-container:hover {
    border-color: var(--primary-color);
}

.checkbox-container input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    height: 20px;
    width: 20px;
    background-color: #eee;
    border-radius: 6px;
    margin-left: auto;
    /* Push to right */
    position: relative;
    transition: 0.2s;
}

.checkbox-container input:checked~.checkmark {
    background-color: var(--accent-color);
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.checkbox-container input:checked~.checkmark:after {
    display: block;
}

.checkbox-container .checkmark:after {
    left: 7px;
    top: 3px;
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* Form Inputs */
.details-section {
    background: #f8f9fa;
    padding: 20px;
    border-radius: var(--border-radius);
    margin-bottom: 25px;
}

.details-section h3 {
    margin-bottom: 15px;
    font-size: 1.1rem;
    color: var(--secondary-color);
}

.input-group {
    position: relative;
    margin-bottom: 15px;
}

.input-group i {
    position: absolute;
    left: 15px;
    top: 50%;
    /* Center strictly */
    transform: translateY(-50%);
    color: #95a5a6;
    pointer-events: none;
    /* Ensure clicks pass through */
}

/* Special handling for textarea icon */
.input-group textarea+i,
.input-group i:has(+ textarea) {
    top: 15px;
    transform: none;
}

/* Re-target logic for textarea since structure is icon then input or vice versa */
.input-group:has(textarea) i {
    top: 15px;
    transform: none;
}

.input-group input,
.input-group textarea {
    width: 100%;
    padding: 12px 15px 12px 45px;
    border: 2px solid #e1e1e1;
    border-radius: 10px;
    font-size: 1rem;
    transition: 0.3s;
    background: white;
}

.input-group input:focus,
.input-group textarea:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
}

/* Security Section */
.security-section {
    margin-bottom: 30px;
    padding: 15px;
    border: 2px dashed #bdc3c7;
    border-radius: var(--border-radius);
    background: #fff;
    text-align: center;
}

.security-section h3 {
    color: var(--secondary-color);
    font-size: 1rem;
    margin-bottom: 10px;
}

.security-box p {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.security-box input {
    width: 60%;
    text-align: center;
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #ccc;
    font-size: 1.1rem;
    margin: 0 auto;
    display: block;
}

.error-msg {
    color: #e74c3c;
    font-size: 0.9rem;
    margin-top: 5px;
    height: 1.2em;
    /* Reserve space */
}

/* Submit Bar */
.total-bar {
    background: var(--secondary-color);
    padding: 20px;
    border-radius: var(--border-radius);
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 5px 15px rgba(44, 62, 80, 0.3);
}

.total-info {
    display: flex;
    flex-direction: column;
}

.total-info span:first-child {
    font-size: 0.8rem;
    opacity: 0.8;
}

.total-info span:last-child {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary-color);
}

#submitBtn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 30px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
    box-shadow: 0 4px 10px rgba(231, 76, 60, 0.3);
}

#submitBtn:hover {
    background: #e67e22;
    transform: translateY(-2px);
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 100;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    justify-content: center;
    align-items: center;
}

.modal-content {
    background: white;
    padding: 40px;
    border-radius: 20px;
    text-align: center;
    width: 90%;
    max-width: 350px;
    animation: popIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes popIn {
    from {
        transform: scale(0.5);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

.modal-icon {
    font-size: 4rem;
    color: var(--accent-color);
    margin-bottom: 20px;
}

.modal h2 {
    color: var(--secondary-color);
    margin-bottom: 10px;
}

#closeModal {
    background: var(--secondary-color);
    color: white;
    border: none;
    padding: 10px 30px;
    border-radius: 20px;
}

/* Gözleme Multi-Item Styles */
.gozleme-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.gozleme-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: white;
    padding: 15px;
    border-radius: 12px;
    border: 1px solid #eee;
    transition: 0.2s;
}

.gozleme-item:hover {
    border-color: var(--primary-color);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.gozleme-info {
    display: flex;
    flex-direction: column;
    text-align: left;
}

.gozleme-info .name {
    font-weight: 600;
    color: var(--secondary-color);
}

.gozleme-info .item-price {
    font-size: 0.9rem;
    color: var(--primary-color);
    font-weight: 700;
}

.item-quantity-controls {
    display: flex;
    align-items: center;
    background: #f1f2f6;
    border-radius: 20px;
    padding: 2px;
}

.qty-btn-small {
    background: white;
    border: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    color: var(--secondary-color);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    transition: 0.2s;
}

.qty-btn-small:hover {
    background: var(--primary-color);
    color: white;
}

.gozleme-qty {
    width: 35px;
    text-align: center;
    border: none;
    background: transparent;
    font-weight: 700;
    color: var(--secondary-color);
    -moz-appearance: textfield;
}

.gozleme-qty::-webkit-outer-spin-button,
.gozleme-qty::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Landing Page Styles */
.landing-container {
    max-width: 900px;
    width: 100%;
    text-align: center;
    padding: 20px;
}

.landing-header {
    margin-bottom: 40px;
    color: white;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.landing-header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    justify-content: center;
}

.selection-card {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    overflow: hidden;
    text-decoration: none;
    color: var(--text-dark);
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
}

.selection-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

.card-image {
    height: 250px;
    overflow: hidden;
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.selection-card:hover .card-image img {
    transform: scale(1.1);
}

.card-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.card-content h2 {
    color: var(--primary-color);
    margin-bottom: 10px;
    font-size: 1.5rem;
}

.card-content p {
    color: var(--secondary-color);
    margin-bottom: 20px;
    flex-grow: 1;
}

.btn-select {
    background: var(--secondary-color);
    color: white;
    padding: 10px 25px;
    border-radius: 25px;
    font-weight: 600;
    transition: 0.3s;
}

.selection-card:hover .btn-select {
    background: var(--primary-color);
}