:root {
    --primary: #2c3e50;
    --primary-dark: #1a252f;
    --primary-light: #34495e;
    --accent: #e74c3c;
    --accent-dark: #c0392b;
    --text: #2c3e50;
    --text-light: #7f8c8d;
    --background: #f8f9fa;
    --surface: #ffffff;
    --border: #e9ecef;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Vazir', sans-serif;
    line-height: 1.7;
    color: var(--text);
    background: var(--background);
    direction: rtl;
}

.layout {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.header {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    padding: 3rem 0 3rem;
    position: relative;
    overflow: hidden;
}

.header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--accent);
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.logo h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 0.2rem;
    letter-spacing: -0.5px;
}

.subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    font-weight: 300;
}

.navigation {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(10px);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.nav-links {
    display: flex;
    gap: 0.5rem;
    padding: 1rem 0;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    color: var(--text-light);
    text-decoration: none;
    border-radius: 12px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.nav-link:hover {
    color: var(--primary);
    background: var(--background);
}

.nav-link.active {
    color: var(--accent);
    background: rgba(231, 76, 60, 0.1);
}

.nav-link i {
    width: 18px;
    height: 18px;
}

.main-content {
    flex: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 3rem 2rem;
    width: 100%;
}

.page {
    display: none;
    animation: fadeInUp 0.6s ease-out;
}

.page.active {
    display: block;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-section {
    margin-bottom: 4rem;
}



.works-header {
    margin-bottom: 3rem;
}

.section-header, .works-header {
    margin-bottom: 2.5rem;
    text-align: center;
}

.section-header h2, .works-header h2 {
    font-size: 2.2rem;
    color: var(--primary);
    margin-bottom: 1rem;
}

.header-accent {
    width: 60px;
    height: 4px;
    background: var(--accent);
    margin: 0 auto;
    border-radius: 2px;
}

.works-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.work-card {
    background: var(--surface);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 1px solid var(--border);
    position: relative;
}

.work-card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 4px;
    height: 100%;
    background: var(--accent);
    transform: scaleY(0);
    transition: transform 0.3s ease;
}

.work-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.work-card:hover::before {
    transform: scaleY(1);
}

.work-card-content {
    padding: 2rem;
}

.work-card h3 {
    font-size: 1.4rem;
    margin-bottom: 1rem;
    color: var(--primary);
}

.work-card p {
    color: var(--text-light);
    line-height: 1.6;
}

.section-top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.back-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--text);
    font-family: 'Vazir', sans-serif;
    font-size: 1rem;
}

.back-btn:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.work-header, .poem-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 3rem;
    gap: 2rem;
}

.work-title-section, .poem-title-section {
    flex: 1;
}

.work-header h2, .poem-header h2 {
    font-size: 2.2rem;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.work-header p, .poem-header p {
    color: var(--text-light);
    font-size: 1.1rem;
}

.icon-btn {
    background: var(--surface);
    border: 1px solid var(--border);
    padding: 0.75rem;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--text-light);
}

.icon-btn:hover {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

.sections-grid {
    display: grid;
    gap: 1.5rem;
}

.section-item {
    background: var(--surface);
    padding: 2rem;
    border-radius: 16px;
    box-shadow: var(--shadow);
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid var(--border);
    border-right: 4px solid var(--accent);
}

.section-item:hover {
    transform: translateX(-8px);
    box-shadow: var(--shadow-lg);
}

.section-item h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: var(--primary);
}

.section-item .date {
    color: var(--text-light);
    font-size: 0.9rem;
}

.poem-container {
    background: var(--surface);
    border-radius: 20px;
    padding: 3rem;
    margin-bottom: 3rem;
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
}

.poem-content {
    font-size: 1.2rem;
    line-height: 2.2;
    white-space: pre-line;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.poem-line {
    margin-bottom: 1rem;
}

.poem-separator {
    margin: 2rem 0;
    text-align: center;
    color: var(--text-light);
    font-size: 1.5rem;
}

.poem-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.nav-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 1.5rem;
    border: 1px solid var(--border);
    background: var(--surface);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Vazir', sans-serif;
    font-size: 1rem;
    color: var(--text);
    min-width: 140px;
}

.nav-btn:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.nav-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.nav-btn:disabled:hover {
    background: var(--surface);
    color: var(--text);
    border-color: var(--border);
}

.nav-btn.prev {
    justify-content: flex-end;
}

.nav-btn.next {
    justify-content: flex-start;
}

.footer {
    background: var(--primary-dark);
    color: white;
    padding: 3rem 0 2rem;
    margin-top: auto;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.footer-info p {
    margin-bottom: 0.5rem;
    opacity: 0.9;
}

.footer-info a {
    color: var(--accent);
    text-decoration: none;
}

.footer-info a:hover {
    text-decoration: underline;
}

.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.modal-content {
    background: var(--surface);
    margin: 10% auto;
    padding: 0;
    border-radius: 20px;
    width: 90%;
    max-width: 500px;
    box-shadow: var(--shadow-lg);
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem 2rem 1rem;
    border-bottom: 1px solid var(--border);
}

.modal-header h3 {
    color: var(--primary);
    font-size: 1.4rem;
}

.close-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-light);
    padding: 0.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.close-btn:hover {
    background: var(--background);
    color: var(--text);
}

.share-options, .share-url-section {
    padding: 1.5rem 2rem;
}

.share-options p, .share-url-section p {
    margin-bottom: 1rem;
    color: var(--text-light);
}

.social-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}

.social-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Vazir', sans-serif;
    font-size: 0.9rem;
    color: white;
}

.social-btn.telegram { background: #0088cc; }
.social-btn.whatsapp { background: #25D366; }
.social-btn.twitter { background: #1DA1F2; }
.social-btn.instagram { 
    background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
}

.social-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.share-url {
    display: flex;
    gap: 1rem;
}

#share-url-input {
    flex: 1;
    padding: 1rem;
    border: 1px solid var(--border);
    border-radius: 12px;
    font-family: 'Vazir', sans-serif;
    background: var(--background);
}

.copy-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 1rem;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.copy-btn:hover {
    background: var(--primary-dark);
}

@media (max-width: 768px) {
    .header-content {
        padding: 0 1rem;
    }
    
    .logo h1 {
        font-size: 2.5rem;
    }
    
    .main-content {
        padding: 2rem 1rem;
    }
    
    
    .works-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .work-header, .poem-header {
        flex-direction: column;
        gap: 1rem;
    }
    
    .section-top-bar {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .poem-navigation {
        flex-direction: column;
    }
    
    .nav-btn {
        width: 100%;
        justify-content: center;
    }
    
    .poem-container {
        padding: 2rem 1rem;
    }
    
    .poem-content {
        font-size: 1.1rem;
    }
    
    .modal-content {
        margin: 20% auto;
        width: 95%;
    }
    
    .share-url {
        flex-direction: column;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 1.5rem;
    }
}

@media (max-width: 480px) {
    .logo h1 {
        font-size: 2rem;
    }
    
    .hero-content h2 {
        font-size: 2rem;
    }
    
    .work-card-content {
        padding: 1.5rem;
    }
    
    .section-item {
        padding: 1.5rem;
    }
    
    .modal-header {
        padding: 1.5rem;
    }
    
    .share-options, .share-url-section {
        padding: 1rem 1.5rem;
    }
}

.about-grid {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 3rem;
    align-items: start;
}

.about-image {
    position: sticky;
    top: 2rem;
}

.image-container {
    position: relative;
    width: 100%;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    margin-bottom: 2rem;
}

.shamlou-image {
    width: 100%;
    height: 400px;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.quick-facts {
    background: var(--surface);
    padding: 2rem;
    border-radius: 16px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
}

.quick-facts h3 {
    color: var(--primary);
    margin-bottom: 1.5rem;
    font-size: 1.3rem;
    border-bottom: 2px solid var(--accent);
    padding-bottom: 0.5rem;
}

.fact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border);
}

.fact-item:last-child {
    border-bottom: none;
}

.fact-item i {
    width: 20px;
    height: 20px;
    color: var(--accent);
}

.fact-item span {
    color: var(--text);
    font-weight: 500;
}

.about-text h2 {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    color: var(--primary);
    text-align: center;
}

.about-card {
    background: var(--surface);
    padding: 3rem;
    border-radius: 20px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
}

.bio-section {
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border);
}

.bio-section:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.bio-section h3 {
    color: var(--primary);
    font-size: 1.4rem;
    margin-bottom: 1rem;
    padding-right: 1rem;
    border-right: 4px solid var(--accent);
}

.bio-section p {
    line-height: 2;
    color: var(--text);
    text-align: justify;
    font-size: 1.1rem;
}

.works-highlights {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.work-highlight {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: var(--background);
    border-radius: 12px;
    border: 1px solid var(--border);
    transition: all 0.3s ease;
}

.work-highlight:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
    border-color: var(--accent);
}

.work-highlight i {
    width: 20px;
    height: 20px;
    color: var(--accent);
}

.work-highlight span {
    color: var(--text);
    font-weight: 500;
}

@media (max-width: 968px) {
    .about-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .about-image {
        position: static;
    }
    
    .quick-facts {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    .fact-item {
        border-bottom: none;
        padding: 0.5rem 0;
    }
}

@media (max-width: 768px) {
    .about-card {
        padding: 2rem;
    }
    
    .quick-facts {
        grid-template-columns: 1fr;
        padding: 1.5rem;
    }
    
    .works-highlights {
        grid-template-columns: 1fr;
    }
    
    .bio-section h3 {
        font-size: 1.2rem;
    }
    
    .bio-section p {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .about-card {
        padding: 1.5rem;
    }
    
    .image-placeholder {
        height: 200px;
    }
    
    .placeholder-icon {
        width: 60px;
        height: 60px;
    }
}

