/* --- 1. RESET & VARIABLES --- */
:root {
    --brand-yellow: #FFED00;
    --brand-green:  #219653;
    --brand-dark:   #1a1a1a;
    --bg-light:     #f4f7f6;
    --nav-height:   80px;
    --transition:   all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-light);
    overflow: hidden;
}

/* --- 2. NAVIGATION BAR --- */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(180deg, var(--brand-yellow) 0%, #e6d600 50%, var(--brand-green) 100%);
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    border-bottom: 3px solid var(--brand-green);
    padding: 0 40px;
    height: var(--nav-height);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
}

.logo-text { font-weight: 800; font-size: 26px; text-transform: uppercase; letter-spacing: -1px; }

.nav-right { display: flex; align-items: center; gap: 15px; }

.btn-login, .btn-register {
    text-decoration: none; font-weight: 700; font-size: 13px; padding: 10px 20px; border-radius: 6px;
    background: var(--brand-dark); color: white; transition: var(--transition);
}

.btn-login:hover, .btn-register:hover { background: transparent; color: var(--brand-dark); transform: translateY(-2px); }

.right-img { height: 50px; width: auto; }

/* --- 3. TREE SYSTEM (MARGINS) --- */
.grid-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 25px; padding: 30px;
    height: calc(100vh - var(--nav-height));
    margin-top: var(--nav-height);
    position: relative;
}

.tree-svg { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }

.branch {
    fill: none; stroke: var(--brand-green); stroke-width: 3; stroke-linecap: round;
    opacity: 0.8; filter: drop-shadow(0 0 8px rgba(33, 150, 83, 0.4));
    stroke-dasharray: 1200; stroke-dashoffset: 1200;
    animation: grow 2.5s ease-out forwards;
}

.trunk { stroke-width: 6; }
.leaf { stroke-width: 2; animation-delay: 1s; }

@keyframes grow { to { stroke-dashoffset: 0; } }

/* --- 4. GRID ITEMS (CARDS) --- */
.grid-item {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    border-radius: 20px; padding: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    display: flex; flex-direction: column; justify-content: center;
    z-index: 2; transition: var(--transition);
    border: 1px solid rgba(255,255,255,0.3);
}

.grid-item:hover { transform: scale(1.02); box-shadow: 0 15px 40px rgba(33, 150, 83, 0.1); }

.item-1, .item-4 { grid-column: span 2; }

/* --- 5. ΕΙΔΙΚΟ STYLING ITEM 3 (SITE LINK) --- */
.main-site-card { text-align: center; gap: 15px; }

.main-site-card h4 { color: var(--brand-green); font-size: 1.4rem; }

.site-link-btn {
    text-decoration: none;
    background-color: var(--brand-green);
    color: white;
    padding: 12px 20px;
    border-radius: 10px;
    font-weight: bold;
    font-size: 0.9rem;
    transition: var(--transition);
    display: inline-block;
    margin-top: 10px;
}

.site-link-btn:hover {
    background-color: var(--brand-dark);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

/* --- 6. CONTACT SECTION --- */
.contact-section { flex-direction: row; gap: 30px; }
.contact-info { flex: 1; text-align: left; }
.contact-form { flex: 1.5; display: flex; flex-direction: column; gap: 10px; }
.form-input { padding: 12px; border: 1px solid #ddd; border-radius: 8px; outline: none; }
.submit-btn { background: var(--brand-dark); color: white; border: none; padding: 12px; border-radius: 8px; cursor: pointer; font-weight: bold; transition: var(--transition); }
.submit-btn:hover { background: var(--brand-green); }

/* --- 7. RESPONSIVE --- */
@media (max-width: 768px) {
    body { overflow-y: auto; }
    
    .navbar { 
    height: auto; 
    padding: 8px 15px; 
    flex-direction: row; 
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
}
    
    .logo-text { 
        font-size: 16px; 
    }
    
    .nav-right { 
    flex-direction: row; 
    flex-wrap: wrap;
    gap: 6px; 
    align-items: center; 
    margin-top: 5px;
    width: 100%;
    justify-content: flex-end;
}
    
    .btn-login, .btn-register { 
        font-size: 11px; 
        padding: 6px 10px; 
    }
    
    .right-img { 
    height: 30px;
    margin-left: auto;
}
    
    .grid-container { 
        grid-template-columns: 1fr; 
        grid-template-rows: auto; 
        height: auto; 
        margin-top: 70px;
        padding: 15px;
        gap: 15px;
    }
    
    .item-1, .item-4 { grid-column: span 1; }
    .contact-section { flex-direction: column; }
    .tree-svg { display: none; }
    
    .grid-item {
        padding: 20px;
    }
}



/* --- AUTH PAGES --- */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-light);
}

.auth-card {
    background: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 420px;
}

.auth-logo {
    text-align: center;
    margin-bottom: 30px;
}

.auth-logo img {
    height: 60px;
    margin-bottom: 10px;
}

.auth-logo h2 {
    color: var(--brand-green);
    font-size: 1.5rem;
}

.auth-logo p {
    color: gray;
    font-size: 0.9rem;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 5px;
    font-size: 0.9rem;
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    outline: none;
    transition: border 0.3s ease;
}

.form-group input:focus {
    border-color: var(--brand-green);
}

.auth-btn {
    width: 100%;
    padding: 14px;
    background: var(--brand-green);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
}

.auth-btn:hover {
    background: var(--brand-dark);
    transform: translateY(-2px);
}

.auth-link {
    text-align: center;
    margin-top: 15px;
    font-size: 0.9rem;
    color: gray;
}

.auth-link a {
    color: var(--brand-green);
    font-weight: 600;
    text-decoration: none;
}

/* --- FLASH MESSAGES --- */
.flash-messages {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
}

.flash {
    padding: 12px 20px;
    border-radius: 8px;
    margin-bottom: 10px;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.flash.success { background: #d4edda; color: #155724; }
.flash.error   { background: #f8d7da; color: #721c24; }
.flash.warning { background: #fff3cd; color: #856404; }

/* --- DRAWINGS PAGE --- */
.drawings-main {
    margin-top: 80px;
    padding: 30px;
}

.drawings-container {
    max-width: 1000px;
    margin: 0 auto;
}

.drawings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.drawing-card {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.drawing-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(33,150,83,0.15);
}

.drawing-card h4 { margin-bottom: 8px; }
.drawing-card p  { color: gray; font-size: 0.85rem; margin-bottom: 12px; }

.download-btn {
    background: var(--brand-green);
    color: white;
    padding: 8px 16px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.download-btn:hover { background: var(--brand-dark); }

.welcome-text {
    color: white;
    font-weight: 600;
}

/* --- ADMIN TABLE --- */
.admin-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.admin-table th, .admin-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.admin-table th { background: var(--brand-dark); color: white; }

.status.approved { color: var(--brand-green); font-weight: 600; }
.status.pending  { color: orange; font-weight: 600; }

.approve-btn {
    background: var(--brand-green);
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
}


.reject-btn {
    background: #d9534f;
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.reject-btn:hover { background: #c9302c; }

.admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 1rem;
}

.admin-table th, .admin-table td {
    padding: 16px 20px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.admin-table th {
    background: var(--brand-dark);
    color: white;
    font-size: 1rem;
}

.admin-table tr:hover {
    background: #f9f9f9;
}