/* ========================================
   ArbiInvest - Сброс стилей (Reset CSS)
   ======================================== */

/* Box sizing */
*,
*::before,
*::after {
    box-sizing: border-box;
}

/* Remove default margin and padding */
* {
    margin: 0;
    padding: 0;
}

/* HTML and Body */
html {
    font-size: 16px;
    line-height: 1.5;
    -webkit-text-size-adjust: 100%;
    -webkit-tap-highlight-color: transparent;
    scroll-behavior: smooth;
    height: 100%;
}

body {
    min-height: 100vh;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-size: inherit;
    font-weight: inherit;
}

/* Lists */
ul, ol {
    list-style: none;
}

/* Links */
a {
    color: inherit;
    text-decoration: none;
    background-color: transparent;
}

/* Forms */
button,
input,
optgroup,
select,
textarea {
    font-family: inherit;
    font-size: 100%;
    line-height: inherit;
    margin: 0;
    padding: 0;
    color: inherit;
}

button,
input {
    overflow: visible;
}

button,
select {
    text-transform: none;
}

button,
[type="button"],
[type="reset"],
[type="submit"] {
    -webkit-appearance: button;
    appearance: button;
    cursor: pointer;
}

button:disabled,
[disabled] {
    cursor: not-allowed;
    opacity: 0.6;
}

button::-moz-focus-inner,
[type="button"]::-moz-focus-inner,
[type="reset"]::-moz-focus-inner,
[type="submit"]::-moz-focus-inner {
    border-style: none;
    padding: 0;
}

fieldset {
    min-width: 0;
    padding: 0;
    margin: 0;
    border: 0;
}

legend {
    display: block;
    width: 100%;
    padding: 0;
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
    line-height: inherit;
    white-space: normal;
}

progress {
    vertical-align: baseline;
}

textarea {
    overflow: auto;
    resize: vertical;
}

[type="checkbox"],
[type="radio"] {
    box-sizing: border-box;
    padding: 0;
}

[type="number"]::-webkit-inner-spin-button,
[type="number"]::-webkit-outer-spin-button {
    height: auto;
}

[type="search"] {
    -webkit-appearance: textfield;
    appearance: textfield;
    outline-offset: -2px;
}

[type="search"]::-webkit-search-decoration {
    -webkit-appearance: none;
}

::-webkit-file-upload-button {
    -webkit-appearance: button;
    font: inherit;
}

/* Media */
img,
svg,
video,
canvas,
audio,
iframe,
embed,
object {
    display: block;
    max-width: 100%;
}

img,
video {
    height: auto;
}

img {
    border-style: none;
}

svg {
    overflow: hidden;
    vertical-align: middle;
}

/* Tables */
table {
    border-collapse: collapse;
    border-spacing: 0;
}

caption {
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
    text-align: left;
    caption-side: bottom;
}

th {
    text-align: inherit;
}

/* Hidden elements */
[hidden] {
    display: none !important;
}

/* Details and Summary */
details {
    display: block;
}

summary {
    display: list-item;
    cursor: pointer;
}

/* Template */
template {
    display: none;
}

/* Abbreviations */
abbr[title] {
    text-decoration: underline dotted;
    cursor: help;
    border-bottom: 0;
}

/* Address */
address {
    font-style: normal;
    line-height: inherit;
}

/* Code elements */
code,
kbd,
pre,
samp {
    font-family: monospace, monospace;
    font-size: 1em;
}

/* Small text */
small {
    font-size: 80%;
}

/* Sub and Sup */
sub,
sup {
    font-size: 75%;
    line-height: 0;
    position: relative;
    vertical-align: baseline;
}

sub {
    bottom: -0.25em;
}

sup {
    top: -0.5em;
}

/* HR */
hr {
    box-sizing: content-box;
    height: 0;
    overflow: visible;
    border: 0;
    border-top: 1px solid;
    margin: 1rem 0;
}

/* Mark */
mark {
    background-color: #ff0;
    color: #000;
}

/* Strong and Bold */
b,
strong {
    font-weight: bolder;
}

/* Definition */
dfn {
    font-style: italic;
}

/* Block quotes */
blockquote {
    margin: 0;
    padding: 0;
}

/* Inline quotes */
q {
    quotes: none;
}

q::before,
q::after {
    content: '';
    content: none;
}

/* Focus styles - для доступности */
:focus {
    outline: 0;
}

:focus-visible {
    outline: 2px solid currentColor;
    outline-offset: 2px;
}

/* Selection */
::selection {
    background-color: rgba(99, 102, 241, 0.3);
    color: inherit;
}

::-moz-selection {
    background-color: rgba(99, 102, 241, 0.3);
    color: inherit;
}

/* Placeholder */
::-webkit-input-placeholder {
    color: inherit;
    opacity: 0.54;
}

::-moz-placeholder {
    color: inherit;
    opacity: 0.54;
}

:-ms-input-placeholder {
    color: inherit;
    opacity: 0.54;
}

::-ms-input-placeholder {
    color: inherit;
    opacity: 0.54;
}

::placeholder {
    color: inherit;
    opacity: 0.54;
}

/* Scrollbar для Webkit браузеров */
::-webkit-scrollbar {
    width: 12px;
    height: 12px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(155, 155, 155, 0.3);
    border-radius: 6px;
    border: 3px solid transparent;
    background-clip: content-box;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(155, 155, 155, 0.5);
    background-clip: content-box;
}

/* Отключение стилей при печати */
@media print {
    *,
    *::before,
    *::after {
        background: transparent !important;
        color: #000 !important;
        box-shadow: none !important;
        text-shadow: none !important;
    }
    
    a,
    a:visited {
        text-decoration: underline;
    }
    
    a[href]::after {
        content: " (" attr(href) ")";
    }
    
    abbr[title]::after {
        content: " (" attr(title) ")";
    }
    
    a[href^="#"]::after,
    a[href^="javascript:"]::after {
        content: "";
    }
    
    pre,
    blockquote {
        border: 1px solid #999;
        page-break-inside: avoid;
    }
    
    thead {
        display: table-header-group;
    }
    
    tr,
    img {
        page-break-inside: avoid;
    }
    
    img {
        max-width: 100% !important;
    }
    
    p,
    h2,
    h3 {
        orphans: 3;
        widows: 3;
    }
    
    h2,
    h3 {
        page-break-after: avoid;
    }
}