


/* --- ALAPOK ÉS HÁTTÉR --- */
body {
    font-family: 'Bricolage Grotesque', sans-serif;
    font-weight: 400;
    margin: 0;
    padding: 0;
    /* A háttérkép rögzítése */
    background-image: url('fenykepek/background.jpg'); 
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-color: #1a1a1a; /* Tartalék sötét szín */
    color: white;
    min-height: 100vh;
}

/* --- NAVIGÁCIÓ (Felső sáv) --- */
.navbar {
    background-color: rgba(34, 34, 34, 0.9); /* Áttetsző sötét */
    backdrop-filter: blur(10px); /* Modern üveghatás */
    padding: 15px 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 999;
    border-bottom: 1px solid rgba(254, 209, 54, 0.3);
}

.nav-container {
    max-width: 1140px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

/* Ha nincs menü, a logó középre kerül */
.navbar:not(:has(.nav-links)) .nav-container {
    justify-content: center;
}

.nav-logo a {
    color: #fed136;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.5em;
    letter-spacing: 1px;
}

.nav-links ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 10px;
}

.nav-links li a {
    color: white;
    text-decoration: none;
    padding: 8px 15px;
    text-transform: uppercase;
    font-size: 0.85em;
    font-weight: 500;
    transition: 0.3s;
}

.nav-links li a:hover {
    color: #fed136;
}

.logout-btn {
    color: #ff6666 !important;
}

/* --- HEADER (Családi fotó rész) JAVÍTÁSA --- */
.main-header {
    margin-top: 60px !important; /* Fix hely a navbar alatt */
    height: 400px !important;    /* Kicsit növeljük a magasságot */
    width: 100% !important;
    
    /* Fontos: Először a kép, utána a szín kényszerítése */
    background-image: url('fenykepek/csalad.jpg') !important;
    background-repeat: no-repeat !important;
    background-position: center center !important;
    
    /* Váltsunk COVER-re, hogy kitöltse a sávot, ha a contain nem működik */
    background-size: cover !important; 
    
    display: flex !important;
    align-items: center;
    justify-content: center;
    position: relative;
    
    /* Ha a kép nem töltene be, legalább lássuk, hogy ott a helye */
    border-bottom: 2px solid #fed136;
}

.header-content {
    background: rgba(0, 0, 0, 0.5);
    padding: 20px 40px;
    border-radius: 12px;
    border: 1px solid rgba(254, 209, 54, 0.3);
    text-align: center;
}

.header-content h1 {
    color: white;
    text-transform: uppercase;
    font-size: 2.2em;
    margin: 0;
    text-shadow: 2px 2px 10px rgba(0,0,0,0.8);
}

/* --- TARTALOM ÉS KÁRTYÁK --- */
.main-wrapper {
    padding-top: 30px; /* Távolság a headertől */
}

.content-wrapper {
    max-width: 1140px;
    margin: 0 auto;
    padding: 20px;
    min-height: 500px;
}

.info-card {
    background: rgba(33, 37, 41, 0.85) !important;
    backdrop-filter: blur(8px);
    color: white !important;
    border: 1px solid rgba(254, 209, 54, 0.4);
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.info-card h2, .info-card h3, .info-card h4 {
    color: #fed136 !important;
    margin-top: 0;
    letter-spacing: -0.01em;
}

/* --- GOMBOK --- */
.btn-link {
    background-color: #fed136;
    color: #212529 !important;
    padding: 12px 24px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 700;
    display: inline-block;
    transition: 0.3s;
    border: none;
    cursor: pointer;
    font-family: 'Bricolage Grotesque', sans-serif;
    text-transform: uppercase;
    font-size: 0.85em;
}

.btn-link:hover {
    background-color: #e6bc2f;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(254, 209, 54, 0.3);
}

/* --- BEJELENTKEZÉS (INDEX) --- */
.login-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 70vh;
    padding: 20px;
}

.login-box {
    width: 100%;
    max-width: 380px;
    border: 2px solid #fed136 !important;
}

.form-group {
    margin-bottom: 15px;
    text-align: left;
}

.form-group label {
    display: block;
    font-size: 0.75em;
    color: #fed136;
    text-transform: uppercase;
    margin-bottom: 5px;
    letter-spacing: 1px;
}

input[type="text"], input[type="password"], input[type="number"], textarea {
    width: 100%;
    padding: 12px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    color: white;
    font-family: 'Bricolage Grotesque', sans-serif;
    box-sizing: border-box;
}

input:focus, textarea:focus {
    outline: none;
    border-color: #fed136;
    background: rgba(0, 0, 0, 0.5);
}

/* --- TAGOK ÉS GALÉRIA RÁCS --- */
.tag-grid, .galeria-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
}

.tag-card {
    transition: transform 0.3s ease;
    text-decoration: none;
}

.tag-card:hover {
    transform: translateY(-5px);
}

.tag-header-row {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.tag-image-small {
    width: 60px;
    height: 60px;
    border-radius: 10px;
    border: 2px solid #fed136;
    overflow: hidden;
}

.tag-image-small img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* A profilkép konténere */
.tag-kep-wrapper {
    width: 200px;           /* Itt állítsd be a kívánt szélességet */
    height: 250px;          /* Itt állítsd be a kívánt magasságot */
    margin: 0 auto 15px;    /* Középre igazítás és távolság az infótól */
    overflow: hidden;       /* Ami kilóg a keretből, az ne látsszon */
    border-radius: 10px;    /* Lekerekített sarkok (opcionális) */
    border: 2px solid #fed136; /* Egy vékony keret, ami összefogja */
    box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

/* Maga a kép a kereten belül */
.tag-kep-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;      /* EZ A KULCS: Kitölti a keretet torzítás nélkül */
    object-position: center top; /* Ha lefele vág, próbálja az arcot (tetejét) megtartani */
    display: block;
}

/* --- LÁBLÉC --- */
footer {
    background-color: rgba(33, 37, 41, 0.95);
    backdrop-filter: blur(10px);
    color: white;
    padding: 40px 0;
    margin-top: 60px;
    border-top: 3px solid #fed136;
}

.footer-container {
    max-width: 1140px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

.admin-links ul {
    list-style: none;
    display: flex;
    gap: 20px;
    padding: 0;
}

.admin-links a {
    color: #fed136;
    text-decoration: none;
    font-size: 0.8em;
    text-transform: uppercase;
    opacity: 0.8;
}

.admin-links a:hover {
    opacity: 1;
    text-decoration: underline;
}
/* Ünnepi szekció stílusa */
.celebration-section {
    background: linear-gradient(45deg, rgba(254, 209, 54, 0.1), rgba(33, 37, 41, 0.9));
    border: 2px solid #fed136;
    border-radius: 15px;
    margin: 20px auto;
    padding: 15px;
    max-width: 800px;
    box-shadow: 0 0 20px rgba(254, 209, 54, 0.2);
    animation: floatAnim 3s ease-in-out infinite;
}

.celebration-container {
    display: flex;
    align-items: center;
    justify-content: space-around;
    text-align: center;
}

.celebrant-list {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
    margin-top: 10px;
}

.celebrant-item {
    font-size: 1.2rem;
    color: #fff;
}

.celebrant-item .badge {
    background: #fed136;
    color: #212529;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: bold;
    text-transform: uppercase;
    margin-left: 5px;
}

.confetti-icon {
    font-size: 2rem;
}

/* Lebegő animáció */
@keyframes floatAnim {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-5px); }
    100% { transform: translateY(0px); }
}

/* Mobilra optimalizálás */
@media (max-width: 600px) {
    .celebration-container {
        flex-direction: column;
    }
    .celebration-text h3 {
        font-size: 1.1rem;
    }
}
/* Pörgő animáció a töltéshez */
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(254, 209, 54, 0.1);
    border-left-color: #fed136;
    border-radius: 50%;
    margin: 0 auto;
    animation: spin 1s linear infinite;
}

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

/* Halványítás, amikor a gomb le van tiltva */
button:disabled {
    opacity: 0.5;
    cursor: not-allowed !important;
}

/* Globális képvédelem a kártyákhoz */
.info-card img, .tag-card img {
    max-width: 100%;    /* Soha nem lehet szélesebb a kártyánál */
    height: auto;       /* Megtartja az arányokat, nem torzít */
    display: block;
    margin: 0 auto 10px; /* Középre igazítja és ad egy kis helyet alul */
    border-radius: 8px;  /* Hogy passzoljon a kártya stílusához */
}

/* --- MOBIL NÉZET --- */
@media (max-width: 768px) {
    .tag-grid {
        grid-template-columns: repeat(auto-fill, minmax(100%, 1fr)); /* Mobilon egy kártya töltse ki a sort */
    }

    .info-card {
        padding: 15px; /* Kisebb belső margó mobilon, hogy több hely maradjon a képnek */
    }
    
    .nav-container, .footer-container {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .nav-links ul {
        flex-direction: column;
        gap: 5px;
    }

    .main-header {
        height: 200px;
    }

    .header-content h1 {
        font-size: 1.5em;
    }
    .admin-form div[style*="grid-template-columns"] {
        grid-template-columns: 1fr !important; /* A 2-3 oszlopos formokból 1 oszlop lesz */
    }
    table {
        display: block;
        width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        white-space: nowrap; /* Hogy ne törje el a szöveget furcsán */
    }

    /* A gombok és beviteli mezők legyenek kicsit nagyobbak mobilon, hogy könnyebb legyen rányomni */
    input, button, .btn-link, .tag-link {
        min-height: 44px; 
        padding: 10px 15px;
    }

}


