/* ============================================
   CORE.CSS - Global Reset, Typography, Animations
   ============================================ */

/* CSS Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Typography System - Standardized */
:root {
    /* Font Family */
    --font-family-base: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    
    /* Font Sizes - Standardized Scale */
    --font-size-xs: 0.75rem;      /* 12px */
    --font-size-sm: 0.875rem;    /* 14px */
    --font-size-base: 1rem;      /* 16px */
    --font-size-lg: 1.125rem;    /* 18px */
    --font-size-xl: 1.25rem;     /* 20px */
    --font-size-2xl: 1.5rem;     /* 24px */
    --font-size-3xl: 1.75rem;    /* 28px */
    --font-size-4xl: 2rem;       /* 32px */
    
    /* Font Weights */
    --font-weight-normal: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;
    
    /* Line Heights */
    --line-height-tight: 1.2;
    --line-height-normal: 1.5;
    --line-height-relaxed: 1.6;
    
    /* Colors */
    --primary-color: #f39200;
    --primary-hover: #e08500;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #17a2b8;
    --text-color: #333;
    --text-muted: #666;
    --text-light: #999;
    --bg-color: #f5f5f0;
    --bg-white: #ffffff;
    --border-color: #e0e0e0;
}

/* Base Body Styles */
body {
    font-family: var(--font-family-base);
    background: linear-gradient(135deg, #f5f5f0 0%, #e8e8e3 50%, #f0f0eb 100%);
    background-attachment: fixed;
    color: var(--text-color);
    line-height: var(--line-height-relaxed);
    margin: 0;
    padding: 0;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    touch-action: manipulation;
    width: 100% !important;
    box-sizing: border-box !important;
}

/* HTML overflow kontrolü */
html {
    width: 100% !important;
    box-sizing: border-box !important;
}

/* Typography Hierarchy */
h1, h2, h3, h4, h5, h6 {
    font-weight: var(--font-weight-semibold);
    line-height: var(--line-height-tight);
    color: var(--text-color);
    margin-bottom: 0.5rem;
}

h1 { font-size: var(--font-size-4xl); }
h2 { font-size: var(--font-size-3xl); }
h3 { font-size: var(--font-size-2xl); }
h4 { font-size: var(--font-size-xl); }
h5 { font-size: var(--font-size-lg); }
h6 { font-size: var(--font-size-base); }

p {
    margin-bottom: 1rem;
    line-height: var(--line-height-relaxed);
}

/* Page Title */
.page-title {
    font-size: var(--font-size-2xl);
    font-weight: var(--font-weight-semibold);
    color: var(--text-color);
    margin-bottom: 1rem;
    margin-top: 0;
    padding-top: 0;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

/* Animations */
@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

@keyframes taskCompletePulse {
    0% {
        transform: translate(-50%, -50%) scale(0) rotate(-10deg);
        opacity: 0;
    }
    50% {
        transform: translate(-50%, -50%) scale(1.1) rotate(5deg);
        opacity: 1;
    }
    100% {
        transform: translate(-50%, -50%) scale(1) rotate(0deg);
        opacity: 0.9;
    }
}

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

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

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

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

@keyframes blink-green {
    0%, 100% {
        opacity: 1;
        box-shadow: 0 0 10px rgba(40, 167, 69, 0.8), inset 0 0 10px rgba(40, 167, 69, 0.3);
    }
    50% {
        opacity: 0.4;
        box-shadow: 0 0 15px rgba(40, 167, 69, 1), inset 0 0 15px rgba(40, 167, 69, 0.5);
    }
}

@keyframes blink-red {
    0%, 100% {
        opacity: 1;
        box-shadow: 0 0 10px rgba(220, 53, 69, 0.8), inset 0 0 10px rgba(220, 53, 69, 0.3);
    }
    50% {
        opacity: 0.4;
        box-shadow: 0 0 15px rgba(220, 53, 69, 1), inset 0 0 15px rgba(220, 53, 69, 0.5);
    }
}

@keyframes pulse-yellow {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.7;
        transform: scale(1.1);
    }
}

@keyframes notification-blink {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(1.2);
    }
}

@keyframes notification-pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(243, 146, 0, 0.7);
    }
    50% {
        box-shadow: 0 0 0 8px rgba(243, 146, 0, 0);
    }
}

@keyframes taskReadPulse {
    0% {
        transform: translate(-50%, -50%) scale(0);
        opacity: 0;
    }
    50% {
        transform: translate(-50%, -50%) scale(1.2);
        opacity: 1;
    }
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.9;
    }
}

/* Utility Classes */
.text-muted {
    color: var(--text-muted);
    font-size: var(--font-size-sm);
}

.text-danger {
    color: var(--danger-color);
}

.text-success {
    color: var(--success-color);
}

.text-primary {
    color: var(--primary-color);
}

/* Revize detay satırları */
tr.revize-detail-row {
    display: none !important;
}

tr.revize-detail-row[data-expanded="true"] {
    display: table-row !important;
}

/* Teklifler - Revize detay satırları (Kalite formundaki gibi) */
tr.quote-revize-detail-row {
    display: none !important;
    transition: all 0.3s ease;
}

tr.quote-revize-detail-row[data-expanded="true"] {
    display: table-row !important;
}

tr.quote-revize-sub-row {
    background-color: #f1f8fa;
}

tr.quote-revize-detail-row:hover {
    background-color: #f8f9fa;
}

