/* ========================================
   AYS SKY LANKA – Modern Portfolio E-commerce UI
   Inspired by: Dark, glass, yellow accent, floating cards
   ======================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Playfair+Display:wght@700;800&display=swap');

/* -------------------------------------------------
   1. Global Reset & Variables
   ------------------------------------------------- */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #FFD700;     /* Gold accent */
    --dark: #0F0F0F;
    --dark-2: #1A1A1A;
    --gray: #2A2A2A;
    --light: #FFFFFF;
    --glass: rgba(255, 255, 255, 0.08);
    --blur: blur(20px);
    --radius: 20px;
    --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--dark);
    color: #ccc;
    line-height: 1.7;
    min-height: 100vh;
    position: relative;
    opacity: 0;
    animation: fadeIn 1s forwards 0.3s;
}

/* -------------------------------------------------
   2. Typography
   ------------------------------------------------- */
h1, h2, h3, h4, h5 {
    font-family: 'Playfair Display', serif;
    color: var(--light);
    font-weight: 800;
    letter-spacing: -0.5px;
}

h1 { font-size: 3.5rem; }
h2 { font-size: 2.5rem; }
h3 { font-size: 1.8rem; }

p { color: #aaa; }

/* -------------------------------------------------
   3. Layout & Container
   ------------------------------------------------- */
.content-wrapper {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* -------------------------------------------------
   4. Header – Minimal, Sticky, Glass
   ------------------------------------------------- */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: var(--glass);
    backdrop-filter: var(--blur);
    -webkit-backdrop-filter: var(--blur);
    border-bottom: 1px solid rgba(255,255,255,0.1);
    transition: var(--transition);
}

header.scrolled {
    background: rgba(15,15,15,0.9);
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

header .content-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

header h1 {
    font-size: 1.4rem;
    color: var(--primary);
    font-weight: 700;
}

header nav a {
    color: #ccc;
    text-decoration: none;
    margin: 0 1rem;
    font-weight: 500;
    position: relative;
    transition: var(--transition);
}

header nav a::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s;
}

header nav a:hover {
    color: var(--primary);
}

header nav a:hover::after {
    width: 100%;
}

.link-icons a {
    color: #ccc;
    font-size: 1.3rem;
    position: relative;
    transition: var(--transition);
}

.link-icons a:hover {
    color: var(--primary);
}

.link-icons span {
    position: absolute;
    top: -8px;
    right: -8px;
    background: var(--primary);
    color: var(--dark);
    font-size: 0.7rem;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

/* -------------------------------------------------
   5. Hero Section – Fullscreen, Diagonal Cut, Glass
   ------------------------------------------------- */
/* ======== HERO - FIXED & ENHANCED ======== */
.featured {
    position: relative;
    height: 100vh;
    min-height: 680px;
    background: 
        linear-gradient(135deg, rgba(15,15,15,0.8) 0%, rgba(26,26,26,0.6) 100%),
        url('imgs/featured-image.jpg') center/cover no-repeat;
    background-attachment: fixed; /* Parallax effect */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
}

.featured::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(45deg, rgba(255,215,0,0.1), transparent 50%);
    backdrop-filter: blur(1px);
    z-index: 1;
    pointer-events: none;
}

.featured .content {
    position: relative;
    z-index: 2;
    padding: 2rem;
    animation: slideUp 1.4s ease-out;
}

.featured h2 {
    font-size: 5.5rem;
    color: #FFD700;
    margin-bottom: 1rem;
    text-shadow: 0 4px 20px rgba(0,0,0,0.8);
    letter-spacing: -2px;
}

.featured p {
    font-size: 1.6rem;
    color: #ffffff;
    max-width: 700px;
    margin: 0 auto;
    font-weight: 300;
    text-shadow: 0 2px 10px rgba(0,0,0,0.6);
}

/* Diagonal cut bottom - enhanced */
.featured::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 220px;
    background: #0F0F0F;
    clip-path: polygon(0 50%, 100% 0, 100% 100%, 0 100%);
    z-index: 2;
}
/* -------------------------------------------------
   6. Recently Added – Floating Glass Cards
   ------------------------------------------------- */
.recentlyadded {
    padding: 6rem 0 4rem;
    position: relative;
    z-index: 2;
}

.recentlyadded h2 {
    text-align: center;
    margin-bottom: 3rem;
    color: var(--light);
    position: relative;
}

.recentlyadded h2::after {
    content: '';
    width: 80px;
    height: 4px;
    background: var(--primary);
    display: block;
    margin: 1rem auto 0;
    border-radius: 2px;
}

.products {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 2rem;
    padding: 0 1rem;
}

.product {
    background: var(--glass);
    backdrop-filter: var(--blur);
    -webkit-backdrop-filter: var(--blur);
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.1);
    transition: var(--transition);
    position: relative;
    animation: fadeUp 0.6s ease-out forwards;
    opacity: 0;
    transform: translateY(30px);
}

.product:nth-child(1) { animation-delay: 0.1s; }
.product:nth-child(2) { animation-delay: 0.2s; }
.product:nth-child(3) { animation-delay: 0.3s; }
.product:nth-child(4) { animation-delay: 0.4s; }

.product:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0,0,0,0.3);
    border-color: rgba(255,215,0,0.3);
}

.product img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.product:hover img {
    transform: scale(1.08);
}

.product .name {
    padding: 1.2rem 1rem 0.4rem;
    font-weight: 600;
    color: var(--light);
    font-size: 1.1rem;
}

.product .price {
    padding: 0 1rem 1.2rem;
    color: var(--primary);
    font-weight: 700;
    font-size: 1.2rem;
}

.product .rrp {
    color: #777;
    text-decoration: line-through;
    font-size: 0.9rem;
    margin-left: 0.5rem;
}

/* -------------------------------------------------
   7. Footer
   ------------------------------------------------- */
footer {
    background: var(--dark-2);
    color: #666;
    text-align: center;
    padding: 2rem 0;
    font-size: 0.9rem;
    border-top: 1px solid rgba(255,255,255,0.05);
}

/* -------------------------------------------------
   8. Animations
   ------------------------------------------------- */
@keyframes fadeIn {
    to { opacity: 1; }
}

@keyframes slideUp {
    from { transform: translateY(50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes fadeUp {
    to { opacity: 1; transform: translateY(0); }
}

/* -------------------------------------------------
   9. Scroll & Header Shrink
   ------------------------------------------------- */
header h1, header nav a, .link-icons a {
    transition: var(--transition);
}

header.scrolled h1,
header.scrolled nav a,
header.scrolled .link-icons a {
    font-size: 0.95em;
}

/* -------------------------------------------------
   10. Responsive
   ------------------------------------------------- */
@media (max-width: 992px) {
    .featured h2 { font-size: 3.5rem; }
    .featured p { font-size: 1.2rem; }
    .products { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    header .content-wrapper { flex-direction: column; gap: 1rem; }
    header nav { order: 3; }
    .featured h2 { font-size: 2.8rem; }
    .products { grid-template-columns: 1fr; }
    .content-wrapper { padding: 0 1rem; }
}