/* =========================================
   STARK DEVELOPER V2 - GLOBAL STYLESHEET
   ========================================= */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

:root {
    --primary: #6c5ce7;
    --secondary: #a29bfe;
    --bg-dark: #121212; /* Ana arka plan */
    --bg-light: #1E1E1E; /* Kart arka planı */
    --bg-light-hover: #2a2a2a; /* Kart hover */
    --text-primary: #f5f6fa; /* Ana metin */
    --text-secondary: #b0b3b8; /* İkincil metin */
    --border-color: #333333;
    --success: #00b894;
    --danger: #d63031;
    
    --arduino: #00979D;
    --linux: #FCC624;
    --html: #E44D26;

    --shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    --shadow-light: 0 5px 15px rgba(0, 0, 0, 0.2);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

/* =========================================
   HEADER & NAVIGATION
   ========================================= */

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 0;
    margin-bottom: 3rem;
    border-bottom: 1px solid var(--border-color);
}

.logo {
    font-size: 1.7rem;
    font-weight: 700;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo i {
    color: var(--primary);
    margin-right: 0.7rem;
    animation: pulse 2s infinite;
}

#logo-typewriter {
    border-right: 2px solid var(--primary);
    white-space: nowrap;
    overflow: hidden;
    display: inline-block;
    animation: blink 1s infinite;
}

.typing-text-header {
    border-right: 2px solid var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    width: 0;
    animation:
        typing 3s steps(15) forwards,
        blink-caret 0.75s step-end infinite;
    font-weight: bold;
}

@keyframes typing {
    from { width: 0 }
    to { width: 15ch }
}

@keyframes blink-caret {
    from, to { border-color: transparent }
    50% { border-color: var(--text-primary) }
}


@keyframes blink {
    0% { border-color: transparent; }
    50% { border-color: var(--primary); }
    100% { border-color: transparent; }
}

nav {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 2rem;
}

nav a {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    transition: all 0.3s ease;
    padding: 0.5rem;
    font-size: 1rem;
    position: relative;
}

nav a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background-color: var(--primary);
    transition: width 0.3s ease;
}

nav a:hover {
    color: var(--text-primary);
}

nav a:hover::after {
    width: 100%;
}

.cart-icon {
    position: relative;
    cursor: pointer;
    color: var(--text-secondary);
    transition: color 0.3s ease;
}

.cart-icon:hover {
    color: var(--primary);
}

.cart-icon i {
    font-size: 1.5rem;
}

#cart-count {
    position: absolute;
    top: -10px;
    right: -10px;
    background: var(--danger);
    color: white;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: 600;
    border: 2px solid var(--bg-dark);
}

/* =========================================
   GENEL SAYFA YAPISI
   ========================================= */
.page-header {
    text-align: center;
    padding: 2rem 0;
    margin-bottom: 2rem;
}

.page-header h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.page-header p {
    font-size: 1.2rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

.back-btn {
    display: inline-block;
    margin-bottom: 2rem;
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.back-btn:hover {
    color: var(--secondary);
    transform: translateX(-5px);
}

.typewriter-title {
    height: 60px;
    overflow: hidden;
    position: relative;
    width: 100%;
    text-align: center;
    margin-bottom: 2rem;
}

.typewriter-title-text {
    position: absolute;
    width: 100%;
    left: 0;
    top: 0;
    opacity: 0;
    animation: typing-title 4s infinite;
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary);
}

@keyframes typing-title {
    0%, 10% { opacity: 0; transform: translateY(-20px); }
    20%, 80% { opacity: 1; transform: translateY(0); }
    90%, 100% { opacity: 0; transform: translateY(20px); }
}


/* =========================================
   GENEL KART YAPISI (Eğitim, Hizmet vb.)
   ========================================= */

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin: 3rem 0;
}

.card {
    background: var(--bg-light);
    border-radius: 15px;
    padding: 2rem;
    text-align: center;
    box-shadow: var(--shadow-light);
    transition: all 0.4s ease;
    border: 1px solid var(--border-color);
    border-top: 4px solid var(--primary);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow);
    background: var(--bg-light-hover);
}

.card i, .card .fab {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
}

.card:hover i, .card:hover .fab {
    transform: scale(1.1) rotate(-5deg);
}

/* Farklı kart icon renkleri */
.card .arduino-icon { color: var(--arduino); }
.card:hover .arduino-icon { color: var(--arduino); }
.card .linux-icon { color: var(--linux); }
.card:hover .linux-icon { color: var(--linux); }
.card .html-icon { color: var(--html); }
.card:hover .html-icon { color: var(--html); }

.card h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.card p {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    min-height: 40px;
    flex-grow: 1;
}

.price {
    font-weight: 700;
    color: var(--primary);
    margin: 1rem 0;
    font-size: 1.8rem;
}

.price-original {
    font-size: 1.1rem;
    color: var(--danger);
    text-decoration: line-through;
    opacity: 0.7;
    margin-left: 0.5rem;
}

.btn {
    display: inline-block;
    padding: 0.9rem 2rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    font-size: 1rem;
    margin-top: 1rem;
    box-shadow: 0 5px 15px rgba(108, 92, 231, 0.3);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn:hover {
    background: var(--secondary);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(162, 155, 254, 0.4);
}

.btn-secondary {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

.btn-secondary:hover {
    background: var(--primary);
    color: white;
}

/* =========================================
   PAKET DETAY KARTLARI (arduino.html vb.)
   ========================================= */

.package-card {
    background: var(--bg-light);
    border-radius: 15px;
    padding: 2.5rem;
    width: 340px;
    box-shadow: var(--shadow);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
    border-top: 5px solid var(--primary);
}

.package-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 30px 50px rgba(0, 0, 0, 0.4);
}

.package-badge {
    position: absolute;
    top: 25px;
    right: -40px;
    background: var(--warning);
    color: var(--bg-dark);
    padding: 0.5rem 3rem;
    font-weight: bold;
    transform: rotate(45deg);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    font-size: 0.9rem;
    z-index: 1;
}

.package-title {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
    text-align: center;
}

.package-price {
    font-size: 3rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 2rem;
    color: var(--primary);
    position: relative;
    display: inline-block;
    width: 100%;
}

.package-price-original {
    position: absolute;
    top: -15px;
    right: 0;
    left: 0;
    font-size: 1.2rem;
    color: var(--danger);
    text-decoration: line-through;
    opacity: 0.7;
}

.package-features {
    list-style: none;
    margin-bottom: 2rem;
}

.package-features li {
    padding: 0.8rem 0;
    border-bottom: 1px dashed var(--border-color);
    display: flex;
    align-items: center;
    color: var(--text-secondary);
}

.package-features li i {
    margin-right: 0.7rem;
    color: var(--success);
}

/* Paket Renkleri */
.package-arduino .package-card { border-top-color: var(--arduino); }
.package-arduino .package-price { color: var(--arduino); }
.package-arduino .btn { background: var(--arduino); box-shadow: 0 5px 15px rgba(0, 151, 157, 0.4); }
.package-arduino .btn:hover { background: #00b8c0; }

.package-linux .package-card { border-top-color: var(--linux); }
.package-linux .package-price { color: var(--linux); }
.package-linux .btn { background: var(--linux); color: var(--bg-dark); box-shadow: 0 5px 15px rgba(252, 198, 36, 0.4); }
.package-linux .btn:hover { background: #ffd34e; }

.package-html .package-card { border-top-color: var(--html); }
.package-html .package-price { color: var(--html); }
.package-html .btn { background: var(--html); box-shadow: 0 5px 15px rgba(228, 77, 38, 0.4); }
.package-html .btn:hover { background: #f16529; }


/* =========================================
   FOOTER
   ========================================= */

footer {
    text-align: center;
    padding: 3rem 0;
    margin-top: 4rem;
    border-top: 1px solid var(--border-color);
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1.5rem;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.footer-links a:hover {
    color: var(--primary);
    text-decoration: underline;
}

.copyright {
    font-size: 0.9rem;
    color: var(--text-secondary);
    opacity: 0.7;
}

/* =========================================
   SEPET MODAL (POPUP)
   ========================================= */

.cart-modal {
    display: none; /* JS ile 'flex' yapılacak */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 1000;
    justify-content: flex-end; /* Sağda açılır */
    animation: fadeIn 0.3s ease;
}

.cart-content {
    background: var(--bg-light);
    width: 100%;
    max-width: 450px;
    height: 100%;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.5);
    transform: translateX(100%);
    animation: slideIn 0.4s forwards ease-out;
}

.cart-modal.show .cart-content {
    transform: translateX(0);
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.cart-header h2 {
    font-size: 1.5rem;
}

.close-cart {
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

.close-cart:hover {
    color: var(--danger);
    transform: rotate(90deg);
}

.cart-items {
    flex: 1;
    overflow-y: auto;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 0;
    border-bottom: 1px solid var(--border-color);
}

.cart-item-info {
    flex: 1;
    padding-right: 1rem;
}

.cart-item-title {
    font-weight: 600;
    margin-bottom: 0.3rem;
    font-size: 1.1rem;
}

.cart-item-price {
    color: var(--primary);
    font-weight: 600;
    font-size: 1rem;
}

.cart-item-remove {
    color: var(--danger);
    background: none;
    border: none;
    cursor: pointer;
    margin-left: 1rem;
    font-size: 1.2rem;
    transition: transform 0.2s ease;
}

.cart-item-remove:hover {
    transform: scale(1.2);
}

.cart-footer {
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

.cart-total {
    display: flex;
    justify-content: space-between;
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.cart-total-label {
    color: var(--text-secondary);
}

.cart-total-price {
    color: var(--primary);
}

.empty-cart {
    text-align: center;
    padding: 3rem 0;
    color: var(--text-secondary);
}

.empty-cart i {
    font-size: 3rem;
    display: block;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* =========================================
   ANİMASYONLAR
   ========================================= */

/* Modal animasyonları */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { transform: translateX(100%); }
    to { transform: translateX(0); }
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* Kaydırmalı animasyon için */
.reveal {
    opacity: 0;
    transform: translateY(60px);
    transition: all 1s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* =========================================
   İLETİŞİM FORMU (İletişim sayfası için)
   ========================================= */
.contact-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.contact-card {
    background: var(--bg-light);
    border-radius: 10px;
    padding: 2.5rem;
    box-shadow: var(--shadow-light);
    transition: all 0.3s ease;
    text-align: center;
    border-top: 4px solid var(--primary);
}

.contact-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.contact-icon {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.contact-card h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.contact-info {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.contact-link {
    color: var(--primary);
    text-decoration: none;
    transition: all 0.3s ease;
    display: block;
    margin-top: 1rem;
    font-weight: 600;
}

.contact-link:hover {
    text-decoration: underline;
}

.contact-form {
    background: var(--bg-light);
    border-radius: 10px;
    padding: 2.5rem;
    box-shadow: var(--shadow);
    margin-top: 2rem;
    border-top: 4px solid var(--primary);
}

.form-title {
    font-size: 1.8rem;
    margin-bottom: 2rem;
    color: var(--text-primary);
    text-align: center;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 1rem;
    color: var(--text-secondary);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 1rem;
    border: 1px solid var(--border-color);
    background: var(--bg-dark);
    border-radius: 5px;
    font-size: 1rem;
    color: var(--text-primary);
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.2);
}

.form-group textarea {
    height: 150px;
    resize: vertical;
}

/* =========================================
   TEŞEKKÜR SAYFASI (tesekkur.html)
   ========================================= */
.success-message {
    background: var(--bg-light);
    border-radius: 10px;
    padding: 3rem;
    box-shadow: var(--shadow);
    text-align: center;
    margin: 3rem auto;
    max-width: 600px;
    border-top: 4px solid var(--success);
}

.success-icon {
    font-size: 4rem;
    color: var(--success);
    margin-bottom: 1.5rem;
    animation: pulse 1s ease-in-out;
}

.success-message h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.success-message p {
    font-size: 1.1rem;
    color: var(--text-secondary);
}

.success-message .contact-btn {
    display: inline-block;
    padding: 0.8rem 1.5rem;
    background: var(--primary);
    color: white;
    border-radius: 5px;
    text-decoration: none;
    transition: all 0.3s ease;
    margin-top: 1.5rem;
}

.success-message .contact-btn:hover {
    background: var(--secondary);
    transform: translateY(-2px);
}

/* =========================================
   ÖDEME SAYFASI (odeme.html için)
   ========================================= */
.checkout-container {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    margin-top: 2rem;
    align-items: flex-start;
}

.payment-details, .order-summary {
    background: var(--bg-light);
    padding: 2.5rem;
    border-radius: 10px;
    box-shadow: var(--shadow-light);
}

.payment-details h2, .order-summary h2 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

#iyzico-form-placeholder {
    padding: 3rem 1rem;
    border: 2px dashed var(--border-color);
    border-radius: 10px;
    text-align: center;
    color: var(--text-secondary);
    background-color: var(--bg-dark);
}

#iyzico-form-placeholder i {
    font-size: 2rem;
    margin-bottom: 1rem;
    display: block;
}

#summary-items-list {
    list-style: none;
    margin-bottom: 1.5rem;
}

#summary-items-list li {
    display: flex;
    justify-content: space-between;
    padding: 0.8rem 0;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.9rem;
}

#summary-total {
    font-size: 1.2rem;
    font-weight: 700;
    display: flex;
    justify-content: space-between;
    margin-top: 1rem;
    color: var(--primary);
}


/* =========================================
   RESPONSIVE
   ========================================= */

@media (max-width: 992px) {
    .checkout-container {
        grid-template-columns: 1fr;
    }

    .card-grid {
        justify-content: center;
    }
}


@media (max-width: 768px) {
    header {
        flex-direction: column;
        gap: 1.5rem;
    }

    nav {
        flex-direction: column;
        width: 100%;
    }

    nav ul {
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }

    .cart-icon {
        margin-top: 0.5rem;
    }

    .page-header h1 {
        font-size: 2.5rem;
    }
    
    .page-header p {
        font-size: 1.1rem;
    }

    .card-grid {
        grid-template-columns: 1fr;
    }

    .contact-container {
        grid-template-columns: 1fr;
    }
}