/* --- AssabTigle Design System --- */

:root {
    /* Color Palette */
    --bg-color: #ffffff;
    --text-main: #0a0a0a;
    --text-muted: #666666;
    --text-light: #999999;
    
    --border-light: #f0f0f0;
    --border-strong: #0a0a0a;
    
    /* Typography */
    --font-heading: 'Space Grotesk', sans-serif;
    --font-body: 'Inter', sans-serif;
    
    /* Layout */
    --spacing-container: 40px;
    --max-width: 1100px;
}

/* --- Reset & Base --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* Texture: Subtle Noise Overlay */
.noise-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    pointer-events: none;
    z-index: 9999;
    opacity: 0.03;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

a { text-decoration: none; color: inherit; transition: all 0.2s ease; }
ul { list-style: none; }

/* --- Layout Utilities --- */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--spacing-container);
    position: relative;
    z-index: 1;
}

.section { padding: 100px 0; }

/* --- Typography --- */
h1, h2, h3, .brand { font-family: var(--font-heading); }

h1 {
    font-size: 4.5rem;
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.04em;
    color: var(--text-main);
    margin-bottom: 30px;
}

h2 { font-size: 2rem; letter-spacing: -0.03em; }

.subtitle {
    font-size: 1.25rem;
    color: var(--text-muted);
    font-weight: 300;
    max-width: 600px;
}

.label-text {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--text-light);
    font-weight: 600;
}

/* --- Header --- */
header {
    padding: 40px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.05em;
}
.brand .dot { color: var(--text-light); }

.back-btn {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-muted);
}
.back-btn:hover { color: var(--text-main); }

/* --- Hero Section --- */
.hero { padding-top: 80px; padding-bottom: 120px; }

/* --- Section Dividers --- */
.section-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 60px;
}
.line {
    height: 1px;
    background: var(--border-light);
    flex-grow: 1;
}

/* --- Components: App Grid (Updated Layout) --- */
.app-grid {
    display: grid;
    /* Broader cards for a premium feel */
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); 
    gap: 32px;
}

.app-card {
    background: #ffffff;
    border: 1px solid #eeeeee; /* Very subtle border initially */
    border-radius: 4px; /* Almost sharp, very technical look */
    padding: 40px;
    height: 320px; /* Fixed height for consistency */
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    position: relative;
    overflow: hidden;
}

/* Hover Effect: High Contrast & Lift */
.app-card:hover {
    border-color: #000000; /* Monochrome pop */
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.06);
}

/* Internal Layout: Header */
.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.app-icon-small {
    width: 72px; 
    height: 72px;
    border-radius: 18px;
    object-fit: cover;
    /* Soft shadow behind icon to make it pop off the white card */
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
    transition: transform 0.4s ease;
}

.app-card:hover .app-icon-small {
    transform: scale(1.05);
}

.card-arrow-icon {
    color: var(--text-light);
    transition: all 0.3s ease;
}

/* Arrow moves diagonally on hover */
.app-card:hover .card-arrow-icon {
    color: #000;
    transform: translate(4px, -4px);
}

/* Internal Layout: Body */
.card-body {
    margin-top: auto; /* Pushes text to bottom */
}

.app-card h3 { 
    font-size: 1.75rem; /* Much larger title */
    margin-bottom: 8px; 
    color: var(--text-main);
}

.app-card p { 
    font-size: 1rem; 
    color: var(--text-muted);
    line-height: 1.5;
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 16px 32px;
    font-weight: 600;
    font-size: 1rem;
    border-radius: 8px; /* Subtle tech roundness */
    transition: all 0.2s ease;
}

.btn-primary {
    background: var(--text-main);
    color: white;
    border: 1px solid var(--text-main);
}
.btn-primary:hover {
    background: transparent;
    color: var(--text-main);
}

.btn-small { padding: 10px 20px; font-size: 0.85rem; }

/* --- App Detail Page Layout --- */
.app-detail-layout {
    display: grid;
    grid-template-columns: 350px 1fr; /* Sidebar Layout */
    gap: 80px;
    margin-top: 60px;
}

/* Detail Info Column (Sticky) */
.app-info-col {
    position: sticky;
    top: 40px;
    align-self: start;
}

.app-hero-icon img {
    width: 100px; height: 100px;
    border-radius: 22px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}
.app-hero-icon .placeholder {
    width: 100px; height: 100px;
    background: black; border-radius: 22px;
    margin-bottom: 30px;
}

.detail-title { font-size: 3rem; margin-bottom: 10px; }
.detail-tagline { 
    font-size: 1.25rem; 
    font-family: var(--font-body); 
    font-weight: 400; 
    color: var(--text-muted); 
    margin-bottom: 30px; 
}
.detail-desc { 
    font-size: 1rem; 
    color: var(--text-muted); 
    margin-bottom: 40px; 
}

.cta-group { margin-bottom: 40px; }

.legal-links { display: flex; gap: 10px; align-items: center; font-size: 0.85rem; }
.link-subtle { color: var(--text-light); text-decoration: underline; }
.link-subtle:hover { color: var(--text-main); }
.divider { color: var(--border-light); }

/* Detail Visuals Column */
.app-visuals-col { padding-top: 10px; }
.app-visuals-col h3 { margin-bottom: 30px; }

.screenshot-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

.screenshot {
    width: 100%;
    height: auto;
    border-radius: 12px;
    border: 1px solid var(--border-light);
    transition: all 0.5s ease;
    /* Monochromatic Touch: Grayscale until hover */
    filter: grayscale(100%);
}

.screenshot:hover {
    filter: grayscale(0%);
    transform: scale(1.02);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

/* --- Footer --- */
footer {
    border-top: 1px solid var(--border-light);
    padding: 40px 0;
    margin-top: 100px;
}
.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.brand-small { font-family: var(--font-heading); font-weight: 700; }
.copyright { color: var(--text-light); font-size: 0.85rem; }

/* --- Legal Pages --- */
.legal-content h1 { font-size: 2.5rem; margin-bottom: 40px; }
.legal-content h2 { margin-top: 40px; font-size: 1.5rem; }
.legal-content p { color: var(--text-muted); margin-bottom: 20px; }
.legal-content ul { color: var(--text-muted); padding-left: 20px; margin-bottom: 20px; }
.legal-content li { margin-bottom: 10px; }

/* --- Animations --- */
.fade-in-up { opacity: 0; animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards; }
.fade-in-down { opacity: 0; animation: fadeInDown 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards; }

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- Mobile Responsiveness --- */
@media (max-width: 768px) {
    :root { --spacing-container: 20px; }
    h1 { font-size: 3rem; }
    
    /* Grid becomes 1 column */
    .app-grid { grid-template-columns: 1fr; }
    .app-card { height: auto; min-height: 280px; }
    
    /* Detail page layout stacking */
    .app-detail-layout { grid-template-columns: 1fr; gap: 40px; }
    .app-info-col { position: relative; top: 0; }
    .screenshot-grid { grid-template-columns: 1fr; }
    .screenshot { max-width: 300px; margin: 0 auto; display: block; }
}