/* Alapok */
body {
    font-family: Arial, sans-serif;
    background-color: #f2f2f2;
    padding: 0px;
    margin: 0;
}

header {
    width: 100%;
    overflow: hidden;
}

header img {
    width: 100%;
    height: auto;
    display: block;
}

h2 {
    text-align: center;
    color: #333;
    margin-bottom: 20px;
}

/* Formok */
.form-box {
    background-color: #fff;
    padding: 25px 30px;
    border-radius: 8px;
    max-width: 800px;
    margin: 0 auto;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.form-row {
    display: flex;
    flex-wrap: wrap;
    margin: -10px;
}

.form-group {
    flex: 1 1 50%;
    padding: 10px;
    box-sizing: border-box;
    min-width: 250px; /* mobilon egy oszlop */
}

label {
    display: block;
    font-weight: bold;
    margin-bottom: 5px;
    color: #555;
}

input[type="text"], select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 14px;
    box-sizing: border-box;
    transition: border-color 0.3s;
    background-color: #fff;
}

input[type="text"]:focus, select:focus {
    border-color: #e53935;
    outline: none;
}

input[type="submit"], .btn-red, .btn-cart {
    background-color: #e53935;
    color: white;
    border: none;
    border-radius: 5px;
    padding: 12px 25px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    text-align: center;
    transition: background-color 0.3s, color 0.3s;
    display: inline-block;
    margin: 15px auto 0 auto;
}

input[type="submit"]:hover, .btn-red:hover, .btn-cart:hover {
    background-color: #d32f2f;
    color: white;
}

input::placeholder {
    color: #aaa;
    font-style: italic;
}

.text-red {
    text-align: center;
    font-size: 20px;
    font-weight: bold;
    color: #e53935;
}

.btn-center {
    display: block;
    text-align: center;
}

.btn-link {
    background: none;
    border: none;
    color: #e53935;
    font-weight: bold;
    text-decoration: none;
    padding: 0;
    cursor: pointer;
    font-size: 14px;
}

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

.btn-delete {
    background: none;       /* nincs háttér */
    border: none;           /* nincs keret */
    color: #e53935;         /* piros szín */
    font-weight: bold;
    text-decoration: none;
    padding: 0;             /* nincs extra padding */
    cursor: pointer;
    font-size: 18px;
}

.btn-delete:hover {
    color: #d32f2f;
}

.back, .back-link a, a {
    color: #e53935;
    font-weight: bold;
    text-decoration: none;
    display: inline-block;
}

.back-link-wrapper {
    text-align: center;
    margin-top: 20px;
}

a:hover, .back-link a:hover {
    text-decoration: underline;
}

/* Általános hibák és loading */
.loading {
    font-style: italic;
    color: #777;
}

.error {
    color: red;
    font-size: 13px;
    margin-top: 3px;
}

/* Kosár */
.cart-container {
    max-width: 800px;
    margin: 0 auto 40px auto;
    background-color: #fff;
    padding: 25px 30px;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.cart-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.cart-table th, .cart-table td {
    padding: 12px;
    border-bottom: 1px solid #ddd;
    text-align: left;
}

.cart-table th {
    background-color: #f2f2f2;
}

.checkout-form {
    text-align: left;
    margin-top: 20px;
}

/* Popup */
.popup-overlay, #popup-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 1000;
}

.popup-window, #popup {
    display: none;
    position: fixed;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    background: #fff;
    padding: 25px 30px;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    z-index: 1001;
    max-width: 400px;
    text-align: center;
}

#popup h3 {
    margin-top: 0;
}

#popup-close {
    display: inline-block;
    margin-top: 15px;
    background-color: #e53935;
    color: #fff;
    padding: 8px 20px;
    border-radius: 5px;
    cursor: pointer;
    text-decoration: none;
}

/* Reszponzív */
@media (max-width: 1150px) {
    .form-group {
        flex: 1 1 100%;
    }
}

@media (max-width: 1150px) {
    .cart-table th, .cart-table td {
        padding: 8px;
    }
    .cart-container, form {
        padding: 15px 20px;
    }
}

/* Error page */
/* Fade-in + slight slide animation */
@keyframes fadeSlideIn {
    0% { opacity: 0; transform: translateY(20px); }
    100% { opacity: 1; transform: translateY(0); }
}

.animate-fadeSlideIn {
    animation: fadeSlideIn 0.8s ease-out forwards;
}

/* Floating animation for the error icon */
@keyframes floating {
    0% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0); }
}

.animate-floating {
    animation: floating 3s ease-in-out infinite;
}

/* ✅ Page centering without Tailwind */
.error-page-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.error-card {
    background: white;
    padding: 40px;
    border-radius: 24px;
    max-width: 500px;
    width: 100%;
    text-align: center;
    box-shadow: 0 10px 25px rgba(0,0,0,0.25);
}

.error-icon {
    font-size: 70px;
    margin-bottom: 20px;
}

.error-text {
    color: #777;
    margin-bottom: 30px;
    line-height: 1.6;
}

#error-popup {
    display: none; /* alapból rejtett */
    position: fixed;
    inset: 0; /* top:0; right:0; bottom:0; left:0 */
    background: rgba(0,0,0,0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

/* Popup ablak */
#error-popup .popup-content {
    background: white;
    padding: 20px 30px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    max-width: 400px;
    width: 90%;
    text-align: center;
    animation: fadeIn 0.3s ease-out;
}

#error-popup .popup-content p {
    color: #e53935;
    font-weight: bold;
    margin-bottom: 20px;
    font-size: 16px;
}

#error-popup .popup-content button {
    background-color: #e53935;
    color: white;
    border: none;
    border-radius: 5px;
    padding: 10px 20px;
    font-size: 14px;
    cursor: pointer;
}

#error-popup .popup-content button:hover {
    background-color: #d32f2f;
}

@keyframes fadeIn {
    0% { opacity: 0; transform: scale(0.9); }
    100% { opacity: 1; transform: scale(1); }
}

