/* ==========================================================================
   SAĞLIK HESAPLAMA ARAÇLARI (MODERN UI)
   File: /public/assets/css/pages/tools.css
   ========================================================================== */

/* --- 1. Ana Sayfa Araç Kartları (Grid) --- */
.tools-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); 
    gap: 2rem; 
    margin-top: 2rem; 
}

.tool-card { 
    display: flex; 
    flex-direction: column; 
    background: var(--bg-surface, #ffffff); 
    border: 1px solid var(--border-subtle, #e5e7eb); 
    border-radius: 24px; 
    padding: 2.5rem 2rem; 
    text-decoration: none; 
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1); 
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
}

.tool-card:hover { 
    transform: translateY(-8px); 
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08); 
    border-color: transparent;
}

.tool-icon { 
    width: 70px; 
    height: 70px; 
    border-radius: 18px; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    font-size: 2rem; 
    color: white; 
    margin-bottom: 1.5rem;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.tool-content h3 { 
    color: var(--text-main, #111827); 
    font-size: 1.4rem; 
    font-weight: 800; 
    margin-bottom: 0.75rem; 
    letter-spacing: -0.5px;
}

.tool-content p { 
    color: var(--text-muted, #6b7280); 
    font-size: 1rem; 
    line-height: 1.6; 
    flex-grow: 1; 
    margin-bottom: 1.5rem; 
}

.tool-action { 
    color: var(--primary, #3b82f6); 
    font-weight: 700; 
    font-size: 1rem; 
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: gap 0.3s;
}

.tool-card:hover .tool-action {
    gap: 0.8rem;
}

/* --- Renk ve Yardımcı Sınıflar --- */
.text-sm { font-size: 0.9rem !important; }
.text-blue { color: #3b82f6 !important; }
.text-orange { color: #f97316 !important; }
.text-cyan { color: #06b6d4 !important; }
.text-pink { color: #ec4899 !important; }
.text-rose { color: #f43f5e !important; }
.text-indigo { color: #6366f1 !important; }
.fw-bold { font-weight: 800; }

/* --- Gradient Renkler (İkonlar ve Butonlar İçin) --- */
.bg-gradient-blue { background: linear-gradient(135deg, #60a5fa, #2563eb); }
.bg-gradient-orange { background: linear-gradient(135deg, #fb923c, #ea580c); }
.bg-gradient-cyan { background: linear-gradient(135deg, #22d3ee, #0891b2); }
.bg-gradient-pink { background: linear-gradient(135deg, #f472b6, #db2777); }
.bg-gradient-rose { background: linear-gradient(135deg, #fb7185, #e11d48); }
.bg-gradient-indigo { background: linear-gradient(135deg, #818cf8, #4f46e5); }

/* Uyku Döngüsü Özel Butonu */
.btn-gradient-indigo {
    background: linear-gradient(135deg, #818cf8, #4f46e5);
    color: #ffffff;
    border: none;
    box-shadow: 0 8px 20px rgba(79, 70, 229, 0.3);
    transition: all 0.3s ease;
}
.btn-gradient-indigo:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(79, 70, 229, 0.4);
    color: #ffffff;
}

/* Gebelik Aracı Özel Butonu */
.btn-gradient-pink {
    background: linear-gradient(135deg, #f472b6, #db2777);
    color: white; border: none; transition: all 0.3s ease;
    box-shadow: 0 8px 20px rgba(219, 39, 119, 0.3);
}
.btn-gradient-pink:hover {
    transform: translateY(-2px); color: white;
    box-shadow: 0 12px 25px rgba(219, 39, 119, 0.4);
}

/* Yumurtlama Aracı Özel Butonu */
.btn-gradient-rose {
    background: linear-gradient(135deg, #fb7185, #e11d48);
    color: white; border: none; transition: all 0.3s ease;
    box-shadow: 0 8px 20px rgba(225, 29, 72, 0.3);
}
.btn-gradient-rose:hover {
    transform: translateY(-2px); color: white;
    box-shadow: 0 12px 25px rgba(225, 29, 72, 0.4);
}

/* --- 2. Araç İç Sayfa Düzeni --- */
.tool-page-container { 
    display: flex; 
    gap: 2.5rem; 
    align-items: flex-start; 
    margin-top: 1.5rem; 
}

.tool-main-content { 
    flex: 1; 
}

.tool-sidebar { 
    width: 320px; 
    flex-shrink: 0; 
}

@media (max-width: 991px) { 
    .tool-page-container { flex-direction: column; } 
    .tool-sidebar { width: 100%; } 
}

/* --- 3. Gelişmiş Form Tasarımı (Modern Inputlar) --- */
.tool-form { 
    padding: 1rem 0; 
}

.tool-form .forum-form-label {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 0.6rem;
    display: block;
}

/* Input ve Select Kutuları (Belirgin ve Gölgeleli) */
.tool-form .forum-form-control,
.tool-form .input-lg {
    width: 100%;
    background-color: var(--bg-body);
    border: 2px solid var(--border-subtle);
    border-radius: 16px; 
    padding: 1rem 1.25rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-main);
    transition: all 0.3s ease;
    box-shadow: inset 0 2px 6px rgba(0,0,0,0.03);
}

.tool-form .forum-form-control::placeholder {
    color: #94a3b8;
    font-weight: 500;
}

.tool-form .forum-form-control:focus {
    background-color: var(--bg-surface);
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 5px rgba(59, 130, 246, 0.15), inset 0 1px 2px rgba(0,0,0,0.02);
}

.tool-form .forum-form-control:hover:not(:focus) {
    border-color: #cbd5e1;
}

/* Dev ve Şık Hesapla Butonu */
.tool-form .btn-primary {
    background: linear-gradient(135deg, var(--primary), #1d4ed8);
    border: none;
    border-radius: 16px;
    padding: 1.2rem;
    font-size: 1.2rem;
    font-weight: 800;
    letter-spacing: 0.5px;
    color: white;
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.3);
    transition: all 0.3s ease;
}

.tool-form .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(37, 99, 235, 0.4);
}

/* --- 4. Sonuç Kutuları (Result Box) --- */
.d-none { display: none !important; }

.tool-result-box { 
    background: var(--bg-surface); 
    border-radius: 20px; 
    border: 1px solid var(--border-subtle); 
    box-shadow: 0 10px 40px rgba(0,0,0,0.06); 
    padding: 2.5rem; 
    margin-top: 1rem; 
    position: relative;
    overflow: hidden;
    animation: slideDownFade 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards; 
}

@keyframes slideDownFade { 
    from { opacity: 0; transform: translateY(-20px); } 
    to { opacity: 1; transform: translateY(0); } 
}

/* Üst Vurgu Çizgileri */
.tool-result-box::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; height: 5px;
}
#bmiResultBox::before { background: linear-gradient(90deg, #3b82f6, #2563eb); }
#calorieResultBox::before { background: linear-gradient(90deg, #f97316, #ea580c); }
#waterResultBox::before { background: linear-gradient(90deg, #06b6d4, #0891b2); }
#pregnancyResultBox::before { background: linear-gradient(90deg, #f472b6, #db2777); }
#ovulationResultBox::before { background: linear-gradient(90deg, #fb7185, #e11d48); }
#sleepResultBox::before { background: linear-gradient(90deg, #818cf8, #4f46e5); }

/* --- Sonuç Tasarımları --- */
.result-header h4 { text-align: center; font-size: 1.5rem; font-weight: 800; color: var(--text-main); }

.score-circle { 
    width: 140px; height: 140px; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; margin: 2rem auto; color: white; border: 8px solid rgba(255,255,255,0.3); box-shadow: 0 8px 25px rgba(0,0,0,0.15); transition: background 0.4s;
}
.score-circle span { font-size: 3rem; font-weight: 900; line-height: 1; text-shadow: 0 2px 4px rgba(0,0,0,0.2); }
.score-circle small { font-size: 0.85rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; opacity: 0.9; margin-top: 5px; }

.score-info { background: linear-gradient(135deg, #38bdf8, #0ea5e9); }
.score-success { background: linear-gradient(135deg, #4ade80, #16a34a); }
.score-warning { background: linear-gradient(135deg, #fbbf24, #d97706); }
.score-danger { background: linear-gradient(135deg, #f87171, #dc2626); }

.result-details { text-align: center; color: var(--text-muted); font-size: 1.1rem; line-height: 1.6; font-weight: 500; max-width: 80%; margin: 0 auto; }

/* Tipografi Sınıfları */
.text-huge { font-size: 2.5rem; font-weight: 800; color: var(--text-main); }
.text-lg-muted { font-size: 1.2rem; color: var(--text-muted); margin-top: 10px; }
.val-large { font-size: 1.6rem !important; }
.val-medium { font-size: 1.4rem !important; }

/* Sonuç Kartları (Kalori, Gebelik, Yumurtlama) */
.calorie-results-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; text-align: center; }
.cal-card { background: var(--bg-body); padding: 2rem 1rem; border-radius: 16px; border: 1px solid var(--border-subtle); box-shadow: 0 4px 10px rgba(0,0,0,0.02); transition: transform 0.3s; }
.cal-card:hover { transform: translateY(-5px); box-shadow: 0 10px 20px rgba(0,0,0,0.06); }
.cal-card.maintain { border-bottom: 4px solid var(--primary); }
.cal-card.lose { border-bottom: 4px solid var(--success, #10b981); }
.cal-card.gain { border-bottom: 4px solid var(--warning, #f59e0b); }
.cal-card.border-pink { border-bottom-color: #ec4899; }
.cal-card.border-rose { border-bottom-color: #e11d48; }
.cal-card h5 { font-size: 1rem; font-weight: 700; color: var(--text-muted); margin-bottom: 0.8rem; }
.cal-val { font-size: 2.2rem; font-weight: 900; color: var(--text-main); display: inline-block; }
.cal-card small { font-size: 1rem; font-weight: 600; color: var(--text-dim); }

@media(max-width: 768px) { .calorie-results-grid { grid-template-columns: 1fr; } }

/* Su Aracı Özel */
.water-visual i { filter: drop-shadow(0 4px 6px rgba(6, 182, 212, 0.3)); }

/* Yumurtlama Dönemi Kutusu */
.ovu-window-box {
    background: rgba(225, 29, 72, 0.05);
    border: 1px dashed #e11d48;
    padding: 1.5rem;
    border-radius: 12px;
    margin-top: 1.5rem;
}
.ovu-window-box strong {
    color: #e11d48;
    font-size: 1.25rem;
    font-weight: 800;
    display: block;
    margin-top: 0.5rem;
}

/* Uyku Döngüsü Özel */
.sleep-times-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.25rem;
}

.sleep-time-badge {
    background: var(--bg-body); 
    border: 2px solid #6366f1; 
    border-radius: 16px;
    padding: 1.5rem 1rem; 
    font-size: 1.8rem; 
    font-weight: 800; 
    color: #4f46e5;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.1); 
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    flex: 1 1 calc(50% - 1.25rem);
    min-width: 140px;
}

.sleep-time-badge:hover { 
    transform: translateY(-5px) scale(1.02); 
    box-shadow: 0 8px 25px rgba(99, 102, 241, 0.2);
}

.sleep-time-badge small { 
    display: block; 
    font-size: 0.9rem; 
    font-weight: 600; 
    color: var(--text-muted); 
    margin-top: 8px;
}

/* --- 5. Sidebar Bilgi Paneli --- */
.info-card { background: var(--bg-surface); border: 1px solid var(--border-subtle); padding: 2rem 1.5rem; border-radius: 20px; box-shadow: 0 4px 15px rgba(0,0,0,0.02); }
.info-card h4 { font-size: 1.2rem; font-weight: 800; color: var(--text-main); margin-bottom: 1rem; }
.info-card p { color: var(--text-muted); font-size: 0.95rem; line-height: 1.6; }
.info-list { list-style: none; padding: 0; margin-top: 1.5rem; }
.info-list li { display: flex; align-items: center; justify-content: space-between; padding: 0.8rem 0; border-bottom: 1px dashed var(--border-subtle); font-size: 0.95rem; font-weight: 600; color: var(--text-main); }
.info-list li:last-child { border-bottom: none; }