/* ========================================================================== 1. RESET A ZÁKLADNÍ NASTAVENÍ (Box-sizing podle zadání) ========================================================================== */ *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; } :root { /* Barevná paleta - Vesmírný temný režim s vysokým kontrastem */ --bg-space: #0b0d17; --bg-card: #151926; --text-main: #f0f2f5; --text-muted: #b0b5c1; --accent-blue: #4f46e5; --accent-cyan: #06b6d4; --white: #ffffff; /* Typografie */ --font-primary: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif; } html { scroll-behavior: smooth; font-size: 16px; } body { font-family: var(--font-primary); background-color: var(--bg-space); color: var(--text-main); line-height: 1.6; } /* Pomocný kontejner pro zarovnání obsahu */ .container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; } /* Přístupnost: Skrytí prvku pro běžné oči, ale čitelné pro čtečky obrazovky */ .sr-only-skip { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; } .sr-only-skip:focus { position: static; width: auto; height: auto; background: var(--accent-cyan); color: var(--bg-space); padding: 10px; display: block; text-align: center; font-weight: bold; } /* Klávesnicový focus pro lepší přístupnost (WCAG) */ a:focus, button:focus, input:focus { outline: 3px solid var(--accent-cyan); outline-offset: 2px; } /* ========================================================================== 2. HLAVIČKA A NAVIGACE (Flexbox) ========================================================================== */ .main-header { background-color: rgba(21, 25, 38, 0.9); backdrop-filter: blur(10px); position: sticky; top: 0; z-index: 100; border-bottom: 1px solid rgba(255, 255, 255, 0.1); } .header-wrapper { display: flex; flex-direction: column; /* Mobile first: pod sebou */ align-items: center; padding: 15px 20px; } .logo a { font-size: 1.4rem; font-weight: bold; color: var(--white); text-decoration: none; } .main-nav { margin-top: 15px; } .main-nav ul { display: flex; list-style: none; gap: 20px; } .main-nav a { color: var(--text-muted); text-decoration: none; font-weight: 500; transition: color 0.3s ease; padding: 5px 10px; } .main-nav a:hover, .main-nav a.active { color: var(--accent-cyan); } /* ========================================================================== 3. HERO SEKCE (Úvodní banner) ========================================================================== */ .hero-section { padding: 80px 0; text-align: center; background: radial-gradient(circle at center, #1e1b4b 0%, var(--bg-space) 70%); } .hero-content h1 { font-size: 2.5rem; color: var(--white); margin-bottom: 20px; line-height: 1.2; } .hero-content p { font-size: 1.1rem; color: var(--text-muted); max-width: 600px; margin: 0 auto 30px auto; } /* Tlačítka */ .btn { display: inline-block; padding: 12px 28px; border-radius: 8px; font-weight: 600; text-decoration: none; cursor: pointer; transition: background-color 0.3s ease, transform 0.2s ease; border: none; } .btn-primary { background-color: var(--accent-blue); color: var(--white); } .btn-primary:hover { background-color: #4338ca; transform: translateY(-2px); } .btn-secondary { background-color: transparent; border: 2px solid var(--accent-cyan); color: var(--accent-cyan); width: 100%; } .btn-secondary:hover { background-color: var(--accent-cyan); color: var(--bg-space); } /* ========================================================================== 4. ENCYKLOPEDIE PLANET (CSS Grid - Mobile First) ========================================================================== */ .planets-section { padding: 60px 0; } .planets-section h2, .calculator-section h2 { font-size: 2rem; text-align: center; color: var(--white); margin-bottom: 10px; } .section-subtitle { text-align: center; color: var(--text-muted); margin-bottom: 40px; } /* CSS Grid definice pro karty */ .planets-grid { display: grid; grid-template-columns: 1fr; /* Na mobilu 1 sloupec */ gap: 30px; } .planet-card { background-color: var(--bg-card); border-radius: 12px; overflow: hidden; border: 1px solid rgba(255, 255, 255, 0.05); transition: transform 0.3s ease, box-shadow 0.3s ease; } .planet-card:hover { transform: translateY(-5px); box-shadow: 0 10px 20px rgba(6, 182, 212, 0.1); } .planet-card img { width: 100%; height: 250px; object-fit: cover; /* Aby se obrázek nedeformoval */ background-color: #000; /* fallback než se načte obrázek */ } .card-body { padding: 25px; } .card-body h3 { font-size: 1.5rem; color: var(--white); margin-bottom: 10px; } .card-body p { color: var(--text-muted); margin-bottom: 20px; font-size: 0.95rem; } /* ========================================================================== 5. KALKULAČKA (Flexbox / Form styling) ========================================================================== */ .calculator-section { padding: 60px 0; background-color: rgba(21, 25, 38, 0.5); } .calculator-wrapper { max-width: 600px; margin: 0 auto; } .calc-form { margin-top: 30px; display: flex; flex-direction: column; gap: 15px; } .form-group { display: flex; flex-direction: column; gap: 8px; } .form-group label { font-weight: 500; color: var(--text-main); } .form-group input { padding: 12px; border-radius: 8px; border: 2px solid rgba(255, 255, 255, 0.1); background-color: var(--bg-space); color: var(--white); font-size: 1rem; } .calc-result { margin-top: 30px; padding: 20px; border-radius: 8px; background-color: var(--bg-card); border-left: 4px solid var(--accent-cyan); min-height: 50px; } /* ========================================================================== 6. PATIČKA ========================================================================== */ .main-footer { padding: 40px 0; border-top: 1px solid rgba(255, 255, 255, 0.05); text-align: center; color: var(--text-muted); font-size: 0.9rem; } .footer-wrapper p + p { margin-top: 5px; } /* ========================================================================== 7. RESPONSIVE DESIGN (Média dotazy pro Tablet a Desktop) ========================================================================== */ /* Tablet a širší (nad 600px) */ @media (min-width: 600px) { .header-wrapper { flex-direction: row; /* Navigace a logo vedle sebe */ justify-content: space-between; } .main-nav { margin-top: 0; } .planets-grid { grid-template-columns: repeat(2, 1fr); /* 2 karty vedle sebe */ } .hero-content h1 { font-size: 3.5rem; } } /* Velký desktop (nad 900px) */ @media (min-width: 900px) { .planets-grid { grid-template-columns: repeat(3, 1fr); /* 3 karty vedle sebe */ } } /* ========================================== MODÁLNÍ DIALOG – Detail planety Přidat na konec souboru css/style.css ========================================== */ /* Základní dialog element */ #planet-modal { border: none; border-radius: 20px; padding: 0; background: #0f1117; color: #e8eaf0; max-width: 680px; width: calc(100% - 2rem); max-height: 90vh; overflow: hidden; box-shadow: 0 25px 80px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(255, 255, 255, 0.06); /* Animace otevření */ opacity: 0; transform: translateY(24px) scale(0.97); transition: opacity 0.28s ease, transform 0.28s ease; } #planet-modal.modal-open { opacity: 1; transform: translateY(0) scale(1); } /* Backdrop */ #planet-modal::backdrop { background: rgba(0, 0, 0, 0.75); backdrop-filter: blur(4px); } .modal-inner { display: flex; flex-direction: column; max-height: 90vh; overflow-y: auto; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,0.1) transparent; } /* HLAVIČKA modálu */ .modal-header { display: flex; align-items: flex-start; gap: 1.5rem; padding: 2rem; background: var(--planet-color-light, rgba(193, 68, 14, 0.12)); border-bottom: 1px solid rgba(255, 255, 255, 0.07); position: relative; } /* Vizuální koule planety */ .modal-planet-visual { position: relative; flex-shrink: 0; } .modal-planet-orb { width: 90px; height: 90px; border-radius: 50%; box-shadow: inset -12px -12px 24px rgba(0,0,0,0.5), 0 0 30px rgba(193, 68, 14, 0.35), 0 0 60px rgba(193, 68, 14, 0.1); animation: planetFloat 4s ease-in-out infinite; } .modal-planet-ring { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%) rotateX(75deg); width: 120px; height: 120px; border-radius: 50%; border: 2px solid rgba(193, 68, 14, 0.3); pointer-events: none; } @keyframes planetFloat { 0%, 100% { transform: translateY(0px); } 50% { transform: translateY(-6px); } } /* Text v hlavičce */ .modal-header-text { flex: 1; min-width: 0; } .modal-subtitle { font-size: 0.75rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--planet-color, #c1440e); margin: 0 0 0.25rem; } .modal-header-text h2 { font-size: 2rem; font-weight: 700; margin: 0 0 0.75rem; color: #ffffff; line-height: 1.1; } .modal-description { font-size: 0.9rem; line-height: 1.6; color: #9aa0b0; margin: 0; } /* Tlačítko zavřít */ .modal-close { position: absolute; top: 1rem; right: 1rem; background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 50%; width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; cursor: pointer; color: #9aa0b0; font-size: 0.85rem; transition: background 0.2s, color 0.2s; flex-shrink: 0; } .modal-close:hover { background: rgba(255, 255, 255, 0.12); color: #ffffff; } /* TĚLO modálu */ .modal-body { padding: 1.75rem 2rem 2rem; display: flex; flex-direction: column; gap: 1.75rem; } .modal-section-title { font-size: 0.7rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: #5a6075; margin: 0 0 1rem; } /* Mřížka statistik */ .modal-stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 0.5rem; } .modal-stat { background: rgba(255, 255, 255, 0.03); border: 1px solid rgba(255, 255, 255, 0.06); border-radius: 10px; padding: 0.75rem 1rem; display: flex; flex-direction: column; gap: 0.2rem; } .modal-stat-label { font-size: 0.72rem; color: #5a6075; font-weight: 500; } .modal-stat-value { font-size: 0.95rem; color: #e8eaf0; font-weight: 600; } /* Seznam zajímavostí */ .modal-facts-list { display: flex; flex-direction: column; gap: 0.6rem; } .modal-fact { display: flex; align-items: flex-start; gap: 0.75rem; padding: 0.65rem 0.9rem; background: rgba(255, 255, 255, 0.02); border: 1px solid rgba(255, 255, 255, 0.05); border-radius: 8px; font-size: 0.875rem; color: #b0b8cc; line-height: 1.5; } .modal-fact-icon { font-size: 1.1rem; flex-shrink: 0; margin-top: 0.05rem; } /* Responzivita */ @media (max-width: 600px) { .modal-header { flex-direction: column; align-items: center; text-align: center; padding: 1.5rem; } .modal-header-text h2 { font-size: 1.6rem; } .modal-body { padding: 1.25rem; } .modal-stats-grid { grid-template-columns: 1fr 1fr; } .modal-close { top: 0.75rem; right: 0.75rem; } } /* ========================================== DOPLNĚK – Nové planety + modální dialog Přidat na konec souboru css/style.css ========================================== */ /* Grid planet – 3 sloupce na desktopu, 2 na tabletu, 1 na mobilu */ .planets-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; margin-top: 2.5rem; } @media (max-width: 900px) { .planets-grid { grid-template-columns: repeat(2, 1fr); } } @media (max-width: 560px) { .planets-grid { grid-template-columns: 1fr; } } /* Karta planety */ .planet-card { background: rgba(255, 255, 255, 0.03); border: 1px solid rgba(255, 255, 255, 0.07); border-radius: 16px; overflow: hidden; transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease; display: flex; flex-direction: column; } .planet-card:hover { transform: translateY(-6px); border-color: rgba(255, 255, 255, 0.18); box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4); } .planet-card img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; display: block; background: #0a0c14; } .card-body { padding: 1.25rem; display: flex; flex-direction: column; flex: 1; gap: 0.6rem; } .card-body h3 { margin: 0; font-size: 1.25rem; color: #ffffff; } .card-body p { margin: 0; font-size: 0.875rem; line-height: 1.6; color: #9aa0b0; flex: 1; } /* Tlačítko Detail planety */ .btn-secondary { margin-top: auto; padding: 0.55rem 1.1rem; border-radius: 8px; border: 1px solid rgba(255, 255, 255, 0.15); background: rgba(255, 255, 255, 0.05); color: #e0e4f0; font-size: 0.875rem; font-weight: 600; cursor: pointer; transition: background 0.2s, border-color 0.2s, transform 0.15s; align-self: flex-start; } .btn-secondary:hover { background: rgba(255, 255, 255, 0.1); border-color: rgba(255, 255, 255, 0.28); transform: scale(1.03); } .btn-secondary:active { transform: scale(0.97); } /* ========================================== MODÁLNÍ DIALOG – Detail planety ========================================== */ #planet-modal { border: none; border-radius: 20px; padding: 0; background: #0f1117; color: #e8eaf0; max-width: 680px; width: calc(100% - 2rem); max-height: 90vh; overflow: hidden; box-shadow: 0 25px 80px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(255, 255, 255, 0.06); opacity: 0; transform: translateY(24px) scale(0.97); transition: opacity 0.28s ease, transform 0.28s ease; } #planet-modal.modal-open { opacity: 1; transform: translateY(0) scale(1); } #planet-modal::backdrop { background: rgba(0, 0, 0, 0.75); backdrop-filter: blur(4px); } .modal-inner { display: flex; flex-direction: column; max-height: 90vh; overflow-y: auto; scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, 0.1) transparent; } .modal-header { display: flex; align-items: flex-start; gap: 1.5rem; padding: 2rem; background: var(--planet-color-light, rgba(193, 68, 14, 0.12)); border-bottom: 1px solid rgba(255, 255, 255, 0.07); position: relative; } .modal-planet-visual { position: relative; flex-shrink: 0; } .modal-planet-orb { width: 90px; height: 90px; border-radius: 50%; box-shadow: inset -12px -12px 24px rgba(0, 0, 0, 0.5), 0 0 30px rgba(100, 100, 255, 0.2), 0 0 60px rgba(100, 100, 255, 0.08); animation: planetFloat 4s ease-in-out infinite; } .modal-planet-ring { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%) rotateX(75deg); width: 120px; height: 120px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, 0.1); pointer-events: none; } @keyframes planetFloat { 0%, 100% { transform: translateY(0px); } 50% { transform: translateY(-6px); } } .modal-header-text { flex: 1; min-width: 0; } .modal-subtitle { font-size: 0.75rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--planet-color, #888); margin: 0 0 0.25rem; } .modal-header-text h2 { font-size: 2rem; font-weight: 700; margin: 0 0 0.75rem; color: #ffffff; line-height: 1.1; } .modal-description { font-size: 0.9rem; line-height: 1.6; color: #9aa0b0; margin: 0; } .modal-close { position: absolute; top: 1rem; right: 1rem; background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.1); border-radius: 50%; width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; cursor: pointer; color: #9aa0b0; font-size: 0.85rem; transition: background 0.2s, color 0.2s; flex-shrink: 0; } .modal-close:hover { background: rgba(255, 255, 255, 0.12); color: #ffffff; } .modal-body { padding: 1.75rem 2rem 2rem; display: flex; flex-direction: column; gap: 1.75rem; } .modal-section-title { font-size: 0.7rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: #5a6075; margin: 0 0 1rem; } .modal-stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 0.5rem; } .modal-stat { background: rgba(255, 255, 255, 0.03); border: 1px solid rgba(255, 255, 255, 0.06); border-radius: 10px; padding: 0.75rem 1rem; display: flex; flex-direction: column; gap: 0.2rem; } .modal-stat-label { font-size: 0.72rem; color: #5a6075; font-weight: 500; } .modal-stat-value { font-size: 0.95rem; color: #e8eaf0; font-weight: 600; } .modal-facts-list { display: flex; flex-direction: column; gap: 0.6rem; } .modal-fact { display: flex; align-items: flex-start; gap: 0.75rem; padding: 0.65rem 0.9rem; background: rgba(255, 255, 255, 0.02); border: 1px solid rgba(255, 255, 255, 0.05); border-radius: 8px; font-size: 0.875rem; color: #b0b8cc; line-height: 1.5; } .modal-fact-icon { font-size: 1.1rem; flex-shrink: 0; margin-top: 0.05rem; } @media (max-width: 600px) { .modal-header { flex-direction: column; align-items: center; text-align: center; padding: 1.5rem; } .modal-header-text h2 { font-size: 1.6rem; } .modal-body { padding: 1.25rem; } .modal-stats-grid { grid-template-columns: 1fr 1fr; } .modal-close { top: 0.75rem; right: 0.75rem; } }